Part Number Hot Search : 
1R6U6T SMA4750A ON1865 NSF8KT PE4549 2412WI KRX103 EGL341A
Product Description
Full Text Search
 

To Download CY7C67200-48BAXI Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  cy7c67200 ez-otg? programmable usb on-the-go host/peripheral controller cypress semiconductor corporation ? 198 champion court ? san jose , ca 95134-1709 ? 408-943-2600 document number: 38-08014 rev. *j revised july 31, 2013 ez-otg features single-chip programmable usb dual-role (host/peripheral) controller with two configurable se rial interface engines (sies) and two usb ports supports usb otg protocol on-chip 48-mhz 16-bit processor with dynamically switchable clock speed configurable io block supports a variety of io options or up to 25 bits of general purpose io (gpio) 4k 16 internal mask rom contains built-in bios that supports a communication-ready state with access to i 2 c? eeprom interface, external rom, uart, or usb 8k x 16 internal ram for code and data buffering 16-bit parallel host port interface (hpi) with dma/mailbox data path for an external processor to directly access all on-chip memory and control on-chip sies fast serial port supports from 9600 baud to 2.0m baud spi supports both master and slave supports 12 mhz external crystal or clock 2.7 v to 3.6 v power supply voltage package option: 48-pin fbga typical applications ez-otg is a very powerful and flexible dual-role usb controller that supports a wide variety of applications. it is primarily intended to enable usb otg capability in applications such as: cellular phones pdas and pocket pcs video and digital still cameras mp3 players mass storage devices timer 0 timer 1 watchdog control 4kx16 rom bios 8kx16 ram cy16 16-bit risc core sie1 usb-a sie2 usb-a otg host/ peripheral usb ports d+,d- d+,d- uart i/f hss i/f i2c eeprom i/f hpi i/f spi i/f nreset cy7c67200 gpio [24:0] pll x1 x2 gpio shared input/output pins vbus, id mobile power booster logic block diagram ? cy7c67200 errata: for information on silicon errata, see ?errata? on page 84. details include trigger conditions, devices affected, and proposed workaround.
cy7c67200 document number: 38-08014 rev. *j page 2 of 93 contents introduction ....................................................................... 3 processor core functional over view ............................. 3 processor .................................................................... 3 clocking ....................................................................... 3 memory ....................................................................... 3 interrupts ..................................................................... 3 general timers and watchdog timer ......................... 3 power management ............... .............. .............. ......... 3 interface descriptions ...................................................... 3 usb interface .............................................................. 4 otg interface .............................................................. 4 general purpose io interface ..................................... 4 uart interface [1] ....................................................... 4 i2c eeprom interface [2] ........... ........... ........... ......... 5 serial peripheral interface .. ......................................... 5 high-speed serial interface ... ..................................... 5 host port interface (hpi) ............................................. 6 charge pump interface ............................................... 6 booster interface ......................................................... 7 crystal interface .......................................................... 8 boot configuration interface ........................................ 8 operational modes ...................................................... 9 power savings and reset description ......................... 10 power savings mode description ............................. 10 sleep ......................................................................... 10 external (remote) wakeup so urce ........................... 10 power-on reset (por) description .......................... 10 reset pin ................................................................... 10 usb reset ................................................................. 10 memory map .................................................................... 10 mapping ..................................................................... 10 internal memory ........................................................ 10 registers ......................................................................... 11 processor control registers ..................................... 11 timer registers ......................................................... 18 general usb registers [8] ........................................ 20 usb host only registers .......................................... 22 usb device only registers ... ................................... 30 otg control registers [9] ......................................... 42 gpio registers ......................................................... 43 hss registers ........................................................... 47 hpi registers ............................................................ 53 spi registers ............................................................ 57 uart registers ........................................................ 65 pin diagram ..................................................................... 67 pin descriptions ............................................................. 67 absolute maximum ratings .......................................... 69 operating conditions ..................................................... 69 crystal requirements (xtalin, xtalout) ................. 69 dc characteristics ....................................................... 70 usb transceiver ....................................................... 71 ac timing characteristics ............................................. 71 reset timing ............................................................ 71 clock timing ............................................................. 72 i2c eeprom timing ............. ............... ........... ........ 72 hpi (host port interface) read cycle timing ........... 74 hss byte mode transmit ....................................... 75 hss block mode transmit ....................................... 75 hss byte and block mode receive ................... 75 hardware cts/rts handshake ............................... 76 register summary .......................................................... 77 ordering information ...................................................... 81 ordering code definitions ..... .................................... 81 package diagram ............................................................ 82 acronyms ........................................................................ 83 document conventions ................................................. 83 units of measure ....................................................... 83 errata ............................................................................... 84 part numbers affected .............................................. 84 cy7c67200 qualification status ............ ........... ........ 84 cy7c67200 errata summary .. ............... ........... ........ 84 document history page ................................................. 91 sales, solutions, and legal information ...................... 93 worldwide sales and design s upport ......... .............. 93 products .................................................................... 93 psoc? solutions ...................................................... 93 cypress developer community ................................. 93 technical support ................. .................................... 93
cy7c67200 document number: 38-08014 rev. *j page 3 of 93 introduction ez-otg? (cy7c67200) is cypress semiconductor?s first usb on-the-go (otg) host/periphe ral controller. ez-otg is designed to easily interface to most high-performance cpus to add usb host functionality. ez-otg has its own 16-bit risc processor to act as a coprocessor or operate in standalone mode. ez-otg also has a programmable io interface block allowing a wide range of interface options. processor core functional overview an overview of the processor core components are presented in this section. processor ez-otg has a general purpose 16-bit embedded risc processor that runs at 48 mhz. clocking ez-otg requires a 12 mhz sour ce for clocking. either an external crystal or ttl-level oscillator may be used. ez-otg has an internal pll that produces a 48 mhz internal clock from the 12 mhz source. memory ez-otg has a built-in 4k 16 masked rom and an 8k 16 internal ram. the masked rom contains the ez-otg bios. the internal ram can be used for program code or data. interrupts ez-otg provides 128 interrupt vectors. the first 48 vectors are hardware interrupts and the following 80 vectors are software interrupts. general timers and watchdog timer ez-otg has two built-in programmable timers and a watchdog timer. all three timers can generate an interrupt to the ez-otg. power management ez-otg has one main power-saving mode, sleep. sleep mode pauses all operations and prov ides the lowest power state. interface descriptions ez-otg has a variety of interface options for connectivity, with several interface options available. see ta b l e 1 to understand how the interfaces share pins an d can coexist. below are some general guidelines: i2c eeprom and otg do not conflict with any interfaces hpi is mutually exclusive to hss, spi, and uart table 1. interface options for gpio pins gpio pins hpi hss spi uart i2c otg gpio31 scl/sda gpio30 scl/sda gpio29 otgid gpio24 int gpio23 nrd gpio22 nwr gpio21 ncs gpio20 a1 gpio19 a0 gpio15 d15 cts gpio14 d14 rts gpio13 d13 rxd gpio12 d12 txd gpio11 d11 mosi gpio10 d10 sck gpio9 d9 nssi gpio8 d8 miso gpio7 d7 tx gpio6 d6 rx gpio5 d5 gpio4 d4 gpio3 d3 gpio2 d2 gpio1 d1 gpio0 d0
cy7c67200 document number: 38-08014 rev. *j page 4 of 93 usb interface ez-otg has two built-in host/peri pheral sies that each have a single usb transceiver, meeting the usb 2.0 specification re- quirements for full and low speed (high speed is not supported). in host mode, ez-otg supports two downstream ports; each supports control, interrupt, bulk, and isochronous transfers. in peripheral mode, ez-otg supports one peripheral port with eight endpoints for each of the two sies. endpoint 0 is dedicated as the control endpoint and only supports control transfers. end- points 1 though 7 support interrupt, bulk (up to 64 bytes per pack- et), or isochronous transfers (up to 1023 bytes per packet size). ez-otg also supports a combination of host and peripheral ports simultaneously, as shown in ta b l e 2 . usb features usb 2.0 compatible for full and low speed up to two downstream usb host ports up to two upstream usb peripheral ports configurable endpoint buffers (pointer and length), must reside in internal ram up to eight available peripheral endpoints (1 control endpoint) supports control, interrupt, bulk, and isochronous transfers internal dma channels for each endpoint internal pull up and pull down resistors internal series termination resistors on usb data lines usb pins otg interface ez-otg has one usb port that is compatible with the usb on-the-go supplement to the u sb 2.0 specification. the usb otg port has various hardware features to support session re- quest protocol (srp) and host negotiation protocol (hnp). otg is only supported on usb port 1a. otg features internal charge pump to supply and control vbus vbus valid status (above 4.4 v) vbus status for 2.4 v < vbus < 0.8 v id pin status switchable 2-kohm ? internal discharge resistor on vbus switchable 500-ohm internal pull-up resistor on vbus individually switchable internal pull-up and pull-down resistors on the usb data lines otg pins general purpose io interface ez-otg has up to 25 gpio signals available. several other op- tional interfaces use gpio pins as well and may reduce the over- all number of available gpios. gpio description all inputs are sampled asynchronously with state changes occur- ring at a rate of up to two 48 mhz clock cycles. gpio pins are latched directly into registers, a single flip-flop. unused pin descriptions unused usb pins must be tri-stated with the d+ line pulled high through the internal pull-up resistor and the d? line pulled low through the internal pull-down resistor. unused gpio pins must be conf igured as outputs and driven low. uart interface [1] ez-otg has a built-in uart interface. the uart interface supports data rates from 900 to 115.2k baud. it can be used as a development port or for other interface requirements. the uart interface is exposed through gpio pins. table 2. usb port configuration options port configurations port 1a port 2a otg otg ? otg + 1 host otg host otg + 1 peripheral otg peripheral 1 host + 1 peripheral host peripheral 1 host + 1 peripheral peripheral host 2 hosts host host 1 host host ? 1 host ? host 2 peripherals peripheral peripheral 1 peripheral peripheral ? 1 peripheral ? peripheral table 3. usb interface pins pin name pin number dm1a f2 dp1a e3 dm2a c2 dp2a d3 table 4. otg interface pins pin name pin number dm1a f2 dp1a e3 otgvbus c1 otgid f4 cswitcha d1 cswitchb d2 note 1. errata: the uart is not designed to recognize framing errors. for more information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 5 of 93 uart features supports baud rates of 900 to 115.2k 8-n-1 uart pins i 2 c eeprom interface [2] ez-otg provides a master-only i2c interface for external serial eeproms. the serial eeprom can be used to store application-specific code and data. this i2c interface is only to be used for loading code out of eeprom, it is not a general i2c interface. the i2c eeprom interface is a bios implementation and is exposed through gpio pins. refer to the bios documentation for additional details on this interface. i 2 c eeprom features supports eeproms up to 64 kb (512k bit) auto-detection of eeprom size i 2 c eeprom pins serial peripheral interface ez-otg provides an spi interface for added connectivity. ez-otg may be configured as either an spi master or spi slave. the spi interface can be exposed through gpio pins or the ex- ternal memory port. spi features master or slave mode operation dma block transfer and pio byte transfer modes full duplex or half duplex data communication 8-byte receive fifo and 8-byte transmit fifo selectable master spi clock rates from 250 khz to 12 mhz selectable master spi clock phase and polarity slave spi signaling synchronization and filtering slave spi clock rates up to 2 mhz maskable interrupts for block and byte transfer modes individual bit transfer for non-byte aligned serial communi- cation in pio mode programmable delay timing for the active/inactive master spi clock auto or manual control for master mode slave select signal complete access to internal memory spi pins the spi port has a few different pin location options as shown in ta b l e 7 . the pin location is selectable via the gpio control reg- ister [0xc006]. high-speed serial interface ez-otg provides an hss interface. the hss interface is a pro- grammable serial connection with baud rate from 9600 baud to 2m baud. the hss interface supports both byte and block mode operations as well as hardwar e and software handshaking. com- plete control of ez-otg can be accomplished through this inter- face via an extensible api and communication protocol. the hss interface can be exposed through gpio pins or the external memory port. hss features 8-bit, no parity code programmable baud rate from 9600 baud to 2m baud selectable 1- or 2-stop bit on transmit programmable intercharacter gap timing for block transmit 8-byte receive fifo glitch filter on receive block mode transfer directly to /from ez-otg internal memory (dma transfer) selectable cts/rts hardwar e signal handshake protocol selectable xon/xoff software handshake protocol programmable receive interrupt, block transfer done inter- rupts complete access to internal memory table 5. uart interface pins pin name pin number tx b5 rx b4 table 6. i 2 c eeprom interface pins pin name pin number small eeprom sck h3 sda f3 large eeprom sck f3 sda h3 table 7. spi interface pins pin name pin number nssi f6 or c6 sck d5 mosi d4 miso c5 note 2. errata: if, while the bios is loading fi rmware, the part is reset and at that time the eeprom is drivi ng the sda line low, the bios will configure the part for co-processor mode instead of standalone mode. for more information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 6 of 93 hss pins host port interface (hpi) ez-otg has an hpi interface. the hpi interface provides dma access to the ez-otg internal memory by an external host, plus a bidirectional mailbox register for supporting high-level commu- nication protocols. this port is designed to be the primary high-speed connection to a host processor. complete control of ez-otg can be accomplished through this interface via an extensible api and communicati on protocol. other than the hardware communication protocols, a host processor has identical control over ez-host whether connecting to the hpi or hss port. the hpi interface is exposed through gpio pins. note it should be noted that for up to 3 ms after bios starts executing, gpio[24:19] and gpio[15: 8] will be driven as outputs for a test mode. if these pins ne ed to be used as inputs, a series resistor is required (10 ohm to 48 ohm is recommended). refer to bios documentation for addition details. see section ?reset pin? on page 10 . hpi features 16-bit data bus interface 16 mb/s throughput auto-increment of address pointer for fast block mode transfers direct memory access (dma ) to internal memory bidirectional mailbox register byte swapping complete access to internal memory complete control of sies through hpi dedicated hpi status register hpi pins the two hpi address pins are used to address one of four possible hpi port registers as shown in ta b l e 1 0 below. charge pump interface vbus for the usb on-the-go (otg) port can be produced by ez-otg using its built-in charge pump and some external components. the circuit connecti ons should look similar to figure 1 below. table 8. hss interface pins pin name pin number cts f6 rts e4 rx e5 tx e6 table 9. hpi interface pins [3, 4] pin name pin number int h4 nrd g4 nwr h5 ncs g5 a1 h6 notes 3. hpi_int is for the outgoing mailbox interrupt. 4. hpi strobes are negative logic sampled on rising edge. a0 f5 d15 f6 d14 e4 d13 e5 d12 e6 d11 d4 d10 d5 d9 c6 d8 c5 d7 b5 d6 b4 d5 c4 d4 b3 d3 a3 d2 c3 d1 a2 d0 b2 table 10. hpi addressing hpi a[1:0] a1 a0 hpi data 0 0 hpi mailbox 0 1 hpi address 1 0 hpi status 1 1 figure 1. charge pump table 9. hpi interface pins [3, 4] (continued) pin name pin number cswitcha cy7c67200 cswitchb otgvbus d1 d2 c1 c2 vbus
cy7c67200 document number: 38-08014 rev. *j page 7 of 93 component details: d1 and d2: schottky diodes with a current rating greater than 60 ma. c1: ceramic capacitor with a capacitance of 0.1 f. c2: capacitor value must be no more that 6.5 f since that is the maximum capacitance allowed by the usb otg specifi- cation for a dual-role device. the minimum value of c2 is 1 f. there are no restrictions on the type of capacitor for c2. if the vbus charge pump circuit is not to be used, cswitcha, cswitchb, and otgvbus can be left unconnected. charge pump features meets otg supplement requirements, see table 41, ?dc characteristics: charge pump,? on page 70 . charge pump pins booster interface ez-otg has an on-chip power booster circuit for use with power supplies that range between 2.7 v and 3.6 v. the booster circuit boosts the power to 3.3 v nominal to supply power for the entire chip. the booster circuit requires an external inductor, diode, and capacitor. during power down mode, the circuit is disabled to save power. figure 2 shows how to connect the booster circuit. component details: l1: inductor with inductance of 10 h and a current rating of at least 250 ma d1: schottky diode with a current rating of at least 250 ma c1: tantalum or ceramic capacitor with a capacitance of at least 2.2 f figure 3 shows how to connect the power supply when the booster circuit is not being used. booster pins table 11. charge pump interface pins pin name pin number otgvbus c1 cswitcha d1 cswitchb d2 figure 2. power supply connection with booster boostvcc vswitch vcc avcc c1 d1 l1 3.3v 2.7v to 3.6v power supply figure 3. power supply connection without booster table 12. charge pump interface pins pin name pin number boostvcc f1 vswitch e2 boostvcc vswitch vcc avcc 3.0v to 3.6v power supply
cy7c67200 document number: 38-08014 rev. *j page 8 of 93 crystal interface the recommended crystal circuit to be used with ez-otg is shown in figure 4 . if an oscillator is used instead of a crystal circuit, connect it to xtalin and leave xtalout unconnected. for further information on the crystal requirements, see table 39, ?crystal requirements,? on page 69 . crystal pins boot configuration interface ez-otg can boot into any one of four modes. the mode it boots into is determined by the ttl vo ltage level of gpio [31:30] at the time nreset is deasserted. ta b l e 1 4 shows the different boot pin combinations possible. afte r a reset pin event occurs, the bios bootup procedure executes for up to 3 ms. gpio[31:30] are sampled by the bios during bootup only. after bootup these pins are available to the application as gpios. gpio[31:30] must be pulled high or low, as needed, using resistors tied to v cc or gnd with resistor values between 5k ohm and 15k ohm. gpio[31:30] must not be tied directly to v cc or gnd. note that in standalone mode, the pull ups on those two pins are used for the serial i2c eeprom (if implemented). the resistors used for these pull ups must conform to the serial eeprom manufacturer's requirements. if any mode other then standalone is chosen, ez-otg will be in coprocessor mode. the device will power up with the appropriate communication interface enabled according to its boot pins and wait idle until a coprocessor co mmunicates with it. see the bios documentation for greater detail on the boot process. figure 4. crystal interface table 13. crystal pins pin name pin number xtalin g3 xtalout g2 y1 c1 = 22 pf c2 = 22 pf cy7c67200 xtalin xtalout 12mhz parallel resonant fundamental mode 500uw 20-33pf 5% table 14. boot configuration interface gpio31 (pin 39) gpio30 (pin 40) boot mode 0 0 host port interface (hpi) 0 1 high speed serial (hss) 1 0 serial peripheral interface (spi, slave mode) 1 1 i2c eeprom (standalone mode)
cy7c67200 document number: 38-08014 rev. *j page 9 of 93 operational modes there are two modes of operation: coprocessor and stand- alone. coprocessor mode ez-otg can act as a coprocessor to an external host processor. in this mode, an external host processor drives ez-otg and is the main processor rather then ez-otg?s own 16-bit internal cpu. an external host processor may interface to ez-otg through one of the following three interfaces in coprocessor mode: hpi mode, a 16-bit parallel inte rface with up to 16 mbytes transfer rate hss mode, a serial interface with up to 2m baud transfer rate spi mode, a serial interface with up to 2 mbits/s transfer rate. at bootup gpio[31:30] determine which of these three interfaces are used for coprocessor mode. refer to ta b l e 1 4 for details. bootloading begins from the selected interface after por + 3 ms of bios bootup. standalone mode in standalone mode, there is no external processor connected to ez-otg. instead, ez-otg?s own inte rnal 16-bit cpu is the main processor and firmware is typically downloaded from an eeprom. optionally, firmware ma y also be downloaded via usb. refer to ta b l e 1 4 for booting into standalone mode. after booting into standalone mode (gpio[31:30] = ?11?), the fol- lowing pins are affected: gpio[31:30] are configured as output pins to examine the eeprom contents. gpio[28:27] are enabled for debug uart mode. gpio[29] is configured as otgid for otg applications on port1a. ? if otgid is logic 1 then port1a (otg) is configured as a usb peripheral. ? if otgid is logic 0 then port1a (otg) is configured as a usb host. ports 1b, 2a, and 2b default as usb peripheral ports. all other pins remain input pins. minimum hardware requirements for standalone mode ? peripheral only figure 5. minimum standalone hardware configuration ? peripheral only ez-otg cy7c67200 gpio[30] gpio[31] scl* sda* 10k bootstrap options bootloading firmware *bootloading begins after por + 3ms bios bootup vcc 10k vcc a2 gnd a0 a1 scl sda vcc wp vcc up to 64k x8 eeprom *gpio[31:30] 31 30 up to 2k x8 scl sda >2k x8 to 64k x8 sda scl int. 16k x8 code / data xout xin 12mhz 22pf 22pf nreset reset logic * parallel resonant fundamental mode 500uw 20-33pf 5% vcc, avcc, boostvcc vreg dminus dplus standard-b or mini-b d+ vbus gnd d- shield reserved gnd, agnd, boostgnd
cy7c67200 document number: 38-08014 rev. *j page 10 of 93 power savings and reset description the ez-otg modes and reset cond itions are described in this section. power savings mode description ez-otg has one main power savings mode, sleep. for detailed information on sleep mode; see section ?sleep? . sleep mode is used for usb applications to support usb suspend and non usb applications as the main chip power down mode. in addition, ez-otg is capable of slowing down the cpu clock speed through the cpu speed register [0xc008] without affecting other peripheral timing. reducing the cpu clock speed from 48 mhz to 24 mhz reduces the overall current draw by around 8 ma while reducing it from 48 mhz to 3 mhz reduces the overall current draw by approximately 15 ma. sleep sleep mode is the main chip power down mode and is also used for usb suspend. sleep mode is entered by setting the sleep enable (bit 1) of the power control register [0xc00a]. during sleep mode (usb suspend) the following events and states are true: gpio pins maintain their configuration during sleep (in suspend). external memory address pins are driven low. xtalout is turned off. internal pll is turned off. firmware must disable the char ge pump (otg control register [0xc098]) causing otgvbus to drop below 0.2 v. otherwise otgvbus will only drop to v cc ? (2 schottky diode drops). booster circuit is turned off. usb transceivers is turned off. cpu suspends until a programmable wakeup event. external (remote) wakeup source there are several possible events available to wake ez-otg from sleep mode as shown in ta b l e 1 5 . these may also be used as remote wakeup options for usb applications. see section ?power control register [0xc00a] [r/w]? on page 15 . upon wakeup, code begins executing within 200 ms, the time it takes the pll to stabilize. power-on reset (por) description the length of the power-on-reset event can be defined by (v cc ramp to valid) + (crystal start up). a typical application might utilize a 12-ms power-on-reset event = ~7 ms + ~5 ms, respec- tively. reset pin the reset pin is active low and requires a minimum pulse dura- tion of sixteen 12-mhz clock cycles (1.3 ms). a reset event re- stores all registers to their de fault por settings. code execution then begins 200 ms later at 0xff00 with an immediate jump to 0xe000, the start of bios. note it should be noted that for up to 3 ms after bios starts executing, gpio[24:19] and gpio[15:8] will be driven as outputs for a test mode. if these pins need to be used as inputs, a series resistor is required (10 ohm to 48 ohm is recommended). refer to bios documentation for addition details. usb reset a usb reset affects registers 0xc090 and 0xc0b0, all other registers remain unchanged. memory map memory map information is presented in this section. mapping the ez-otg has just over 24 kb of addressable memory mapped from 0x0000 to 0xffff. this 24 kb contains both program and data space and is byte addressable. figure 6 . shows the various memory region address locations. internal memory of the internal memory, 15 kb is allocated for user?s program and data code. the lower memory space from 0x0000 to 0x04a2 is reserved for interrupt vectors, general purpose registers, usb control registers, the stack, and other bios variables. the upper internal memory space contains ez-otg control registers from 0xc000 to 0xc0ff and the bios rom itself from 0xe000 to 0xffff. for more info rmation on the reserved lower memory or table 15. wakeup sources [5, 6] wakeup source (if enabled) event usb resume d+/d? signaling otgvbus level otgid any edge hpi read hss read spi read irq0 (gpio 24) any edge notes 5. read data will be discarded (dummy data). 6. hpi_int will assert on a usb resume.registers
cy7c67200 document number: 38-08014 rev. *j page 11 of 93 the bios rom, refer to the programmers documentation and the bios documentation. during development with the ez-otg toolset, the lower area of user's space (0x04a4 to 0x1000) should be left available to load the gdb stub. the gdb stub is required to allow the toolset debug access into ez-otg. figure 6. memory map registers some registers have different functions for a read vs. a write access or usb host vs. usb device mode. therefore, registers of this type have multiple definitions for the same address. the default register values listed in this data sheet may be altered to some other value during bios initialization. refer to the bios documentation for register initialization information. processor control registers there are eight registers dedicated to general processor control. each of these registers is covere d in this section and is summa- rized in table 16 . hw ints sw ints 0x0000 - 0x00ff primary registers swap registers usb registers hpi int / mailbox slave setup packet bios user space ~15k internal memory control registers 0x0100 - 0x011f 0x0120 - 0x013f 0x0140 - 0x0148 0x014a - 0x01ff 0x0200- 0x02ff lcp variables 0x0300- 0x030f bios stack 0x0310- 0x03ff usb slave & otg 0x0400- 0x04a2 0x04a4- 0x3fff 0xc000- 0xc0ff 0xe000- 0xffff table 16. processor control registers register name address r/w cpu flags register 0xc000 r register bank register 0xc002 r/w hardware revision register 0xc004 r cpu speed register 0xc008 r/w power control register 0xc00a r/w interrupt enable register 0xc00e r/w breakpoint register 0xc014 r/w usb diagnostic register 0xc03c w
cy7c67200 document number: 38-08014 rev. *j page 12 of 93 cpu flags register [0xc000] [r] figure 7. cpu flags register register description the cpu flags register is a read only register that gives processor flags status. global interrupt enable (bit 4) the global interrupt enable bit indicates if the global interrupts are enabled. 1: enabled 0: disabled negative flag (bit 3) the negative flag bit indicates if an arithmetic operation results in a negative answer. 1: ms result bit is ?1? 0: ms result bit is not ?1? overflow flag (bit 2) the overflow flag bit indicates if an overflow condition has occurred. an overflow condition can occur if an arithmetic result was either larger than the destination operand size (for addition) or smaller than the destination operand should allow for subtraction. 1: overflow occurred 0: overflow did not occur carry flag (bit 1) the carry flag bit indicates if an arithmetic operation resulted in a carry for addition, or borrow for subtraction. 1: carry/borrow occurred 0: carry/borrow did not occur zero flag (bit 0) the zero flag bit indicates if an instruction execution resulted in a ?0?. 1: zero occurred 0: zero did not occur bit # 15 14 13 12 11 10 9 8 field reserved... read/write ? ? ? ? ? ? ? ? default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved global interrupt enable negative flag overflow flag carry flag zero flag read/write ? ? ? r r r r r default 0 0 0 x x x x x
cy7c67200 document number: 38-08014 rev. *j page 13 of 93 bank register [0xc002] [r/w] figure 8. bank register register description the bank register maps registers r0?r15 into ram. the eleven msbs of this register are used as a base address for registers r0?r15. a register address is automatically generated by: 1. shifting the four lsbs of the register address left by 1 2. oring the four shift ed bits of the register address with the 12 msbs of the bank register 3. forcing the lsb to zero for example, if the bank register is left at its default value of 0x0100, and r2 is read, then the physical address 0x0102 will be read. see table 17 for details. . address (bits [15:4]) the address field is used as a base address for all register addresses to start from. reserved all reserved bits must be written as ?0?. hardware revision register [0xc004] [r] figure 9. revision register register description the hardware revision register is a read-only register that indicates the silicon revision number. the first silicon revision is represented by 0x0101. this number is increased by one for each new silicon revision. revision (bits [15:0]) the revision field contains the silicon revision number. bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 1 bit # 7 6 5 4 3 2 1 0 field ...address reserved read/write r/w r/w r/w ? ? ? ? ? default 0 0 0 x x x x x table 17. bank register example register hex value binary value bank 0x0100 0000 0001 0000 0000 r14 0x000e << 1 = 0x001c 0000 0000 0001 1100 ram location 0x011c 0000 0001 0001 1100 bit # 15 14 13 12 11 10 9 8 field revision... read/write r r r r r r r r default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ...revision read/write r r r r r r r r default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 14 of 93 cpu speed register [0xc008] [r/w] figure 10. cpu speed register register description the cpu speed register allows the processor to operate at a user selected speed. this register only affects the cpu; all other peripheral timing is still based on the 48 -mhz system clock (unless otherwise noted). cpu speed (bits[3:0]) the cpu speed field is a divisor that selects the operating speed of the processor as defined in ta b l e 1 8 . reserved all reserved bits must be written as ?0?. bit # 15 14 13 12 11 10 9 8 field reserved... read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved cpu speed read/write - - - - r/w r/w r/w r/w default 0 0 0 0 1 1 1 1 table 18. cpu speed definition cpu speed [3:0] processor speed 0000 48 mhz/1 0001 48 mhz/2 0010 48 mhz/3 0011 48 mhz/4 0100 48 mhz/5 0101 48 mhz/6 0110 48 mhz/7 0111 48 mhz/8 1000 48 mhz/9 1001 48 mhz/10 1010 48 mhz/11 1011 48 mhz/12 1100 48 mhz/13 1101 48 mhz/14 1110 48 mhz/15 1111 48 mhz/16
cy7c67200 document number: 38-08014 rev. *j page 15 of 93 power control register [0xc00a] [r/w] figure 11. power control register register description the power control register controls the power-down and wakeup options. either the sleep mode or the halt mode options can be selected. all other writable bits in this register can be used as a wakeup source while in sleep mode. host/device 2 wake enable (bit 14) the host/device 2 wake enable bit enables or disables a wakeup condition to occur on an host/device 2 transition. this wake up from the sie port does not cause an interrupt to the on-chip cpu. 1: enable wakeup on host/device 2 transition. 0: disable wakeup on host/device 2 transition. host/device 1 wake enable (bit 12) the host/device 1 wake enable bit enables or disables a wakeup condition to occur on an host/device 1 transition. this wakeup from the sie port does not cause an interrupt to the on-chip cpu. 1: enable wakeup on host/device 1 transition 0: disable wakeup on host/device 1 transition otg wake enable (bit 11) the otg wake enable bit enables or disables a wakeup condition to occur on either an otg vbus_valid or otg id transition (irq20). 1: enable wakeup on otg vbus valid or otg id transition 0: disable wakeup on otg vbus valid or otg id transition hss wake enable (bit 9) the hss wake enable bit enables or disables a wakeup condition to occur on an hss rx serial input transition. the processor may take several hundreds of microseconds before being operational after wakeup. therefore, the incoming data byte that causes the wakeup will be discarded. 1: enable wakeup on hss rx serial input transition 0: disable wakeup on hss rx serial input transition spi wake enable (bit 8) the spi wake enable bit enables or disables a wakeup condition to occur on a falling spi_nss input transition. the processor may take several hundreds of microseconds before being opera- tional after wakeup. therefore, the incoming data byte that causes the wakeup will be discarded. 1: enable wakeup on falling spi nss input transition 0: disable spi_nss interrupt hpi wake enable (bit 7) the hpi wake enable bit enables or disables a wakeup condition to occur on an hpi interface read. 1: enable wakeup on hpi interface read 0: disable wakeup on hpi interface read gpi wake enable (bit 4) the gpi wake enable bit enables or disables a wakeup condition to occur on a gpio(25:24) transition. 1: enable wakeup on gp io(25:24) transition 0: disable wakeup on gpio(25:24) transition boost 3v ok (bit 2) the boost 3v ok bit is a read only bit that returns the status of the otg boost circuit. 1: boost circuit not ok and internal voltage rails are below 3.0 v 0: boost circuit ok and internal voltage rails are at or above 3.0 v sleep enable (bit 1) setting this bit to ?1? immediately initiates sleep mode. while in sleep mode, the entire chip is paused achieving the lowest standby power state. all operations are paused, the internal clock is stopped, the booster circuit and otg vbus charge pump are all powered down, and the usb transceivers are powered down. all counters and timers are paused but will retain their values. sleep mode exits by any activity selected in this register. when sleep mode ends, instru ction execution resumes within 0.5 ms. 1: enable sleep mode 0: no function halt enable (bit 0) bit # 15 14 13 12 11 10 9 8 field reserved host/device 2 wake enable reserved host/device 1 wake enable otg wake enable reserved hss wake enable spi wake enable read/write ? r/w ? r/w r/w ? r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field hpi wake enable reserved gpi wake enable reserved boost 3v ok sleep enable halt enable read/write r/w ? ? r/w ? r r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 16 of 93 setting this bit to ?1? immediately initiates halt mode. while in halt mode, only the cpu is stopped . the internal clock still runs and all peripherals still operate, including the usb engines. the power savings using halt in most cases will be minimal, but in applications that are very cpu intensive the incremental savings may provide some benefit. the halt state is exited when any enabled interrupt is triggered. upon exiting the halt state, one or two instructions immediately following the halt instruction may be executed before the waking interrupt is serviced (you may want to follow the halt instruction with two nops). 1: enable halt mode 0: no function reserved all reserved bits must be written as ?0?. interrupt enable register [0xc00e] [r/w] [7] figure 12. interrupt enable register register description the interrupt enable register al lows control of the hardware interrupt vectors. otg interrupt enable (bit 12) the otg interrupt enable bit enables or disables the otg id/otg4.4 v valid hardware interrupt. 1: enable otg interrupt 0: disable otg interrupt spi interrupt enable (bit 11) the spi interrupt enable bit enables or disables the following three spi hardware interrupts: spi tx, spi rx, and spi dma block done. 1: enable spi interrupt 0: disable spi interrupt host/device 2 interrupt enable (bit 9) the host/device 2 interrupt enable bit enables or disables all of the following host/device 2 hardware interrupts: host 2 usb done, host 2 usb sof/eop, host 2 wakeup/insert/remove, device 2 reset, device 2 sof/ eop or wakeup from usb, device 2 endpoint n. 1: enable host 2 and device 2 interrupt 0: disable host 2 and device 2 interrupt host/device 1 interrupt enable (bit 8) the host/device 1 interrupt enable bit enables or disables all of the following host/device 1 hardware interrupts: host 1 usb done, host 1 usb sof/eop, host 1 wakeup/insert/remove, device 1 reset, devi ce 1 sof/eop or wakeup from usb, device 1 endpoint n. 1: enable host 1 and device 1 interrupt 0: disable host 1 and device 1 interrupt hss interrupt enable (bit 7) the hss interrupt enable bit enables or disables the following high-speed serial interface hardware interrupts: hss block done, and hss rx full. 1: enable hss interrupt 0: disable hss interrupt in mailbox interrupt enable (bit 6) the in mailbox interrupt enable bit enables or disables the hpi: incoming mailbox hardware interrupt. 1: enable mbxi interrupt 0: disable mbxi interrupt out mailbox interrupt enable (bit 5) the out mailbox interrupt enable bit enables or disables the hpi: outgoing mailbox hardware interrupt. 1: enable mbxo interrupt 0: disable mbxo interrupt bit # 15 14 13 12 11 10 9 8 field reserved otg interrupt enable spi interrupt enable reserved host/device 2 interrupt enable host/device 1 interrupt enable read/write ? ? ? r/w r/w ? r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field hss interrupt enable in mailbox interrupt enable out mailbox interrupt enable reserved uart interrupt enable gpio interrupt enable timer 1 interrupt enable timer 0 interrupt enable read/write r/w r/w r/w ? r/w r/w r/w r/w default 0 0 0 1 0 0 0 0 note 7. errata: host/device 1 sie events will still trigger an interrupt when onl y the host/device 2 sie interrupt enable is set and vise vers a. for more information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 17 of 93 uart interrupt enable (bit 3) the uart interrupt enable bit enables or disables the following uart hardware interrupts: uart tx and uart rx. 1: enable uart interrupt 0: disable uart interrupt gpio interrupt enable (bit 2) the gpio interrupt enable bit enables or disables the general purpose io pins interrupt (see the gpio control register). when gpio bit is reset, all pen ding gpio interrupts are also cleared. 1: enable gpio interrupt 0: disable gpio interrupt timer 1 interrupt enable (bit 1) the timer 1 interrupt enable bit enables or disables the timer1 interrupt enable. when this bit is reset, all pending timer 1 inter- rupts are cleared. 1: enable tm1 interrupt 0: disable tm1 interrupt timer 0 interrupt enable (bit 0) the timer 0 interrupt enable bit enables or disables the timer0 interrupt enable. when this bit is reset, all pending timer 0 inter- rupts are cleared. 1: enable tm0 interrupt 0: disable tm0 interrupt reserved all reserved bits must be written as ?0?. breakpoint register [0xc014] [r/w] figure 13. breakpoint register register description the breakpoint register holds the breakpoin t address. when the program counter match th is address, the int127 interrupt occurs. to clear this interrupt, a zero value must be written to this register. address (bits [15:0]) the address field is a 16-bit field containing the breakpoint address. bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 18 of 93 usb diagnostic register [0xc03c] [r/w] figure 14. usb diagnostic register register description the usb diagnostic register pr ovides control of diagnostic modes. it is intended for use by device characterization tests, not for normal operations. this register is read/write by the on-chip cpu but is write-only via the hpi port. port 2a diagnostic enable (bit 15) the port 2a diagnostic enable bit enables or disables port 2a for the test conditions selected in this register. 1: apply any of the following enabled test conditions: j/k, dck, se0, rsf, rsl, prd 0: do not apply test conditions port 1a diagnostic enable (bit 15) the port 1a diagnostic enable bit enables or disables port 1a for the test conditions selected in this register. 1: apply any of the following enabled test conditions: j/k, dck, se0, rsf, rsl, prd 0: do not apply test conditions pull-down enable (bit 6) the pull-down enable bit enables or disables full-speed pull-down resistors (pull down on both d+ and d?) for testing. 1: enable pull-down resistors on both d+ and d? 0: disable pull-down resistors on both d+ and d? ls pull-up enable (bit 5) the ls pull-up enable bit enables or disables a low-speed pull-up resistor (pull up on d?) for testing. 1: enable low-speed pull-up resistor on d? 0: pull-up resistor is not connected on d? fs pull-up enable (bit 4) the fs pull-up enable bit enables or disables a full-speed pull-up resistor (pull up on d+) for testing. 1: enable full-speed pull-up resistor on d+ 0: pull-up resistor is not connected on d+ force select (bits [2:0]) the force select field bit selects several different test condition states on the data lines (d+/d?). see ta b l e 1 9 for details. reserved all reserved bits must be written as ?0?. timer registers there are three registers dedicated to timer operations. each of these registers are discussed in this section and are summarized in table 20 . bit # 15 14 13 12 11 10 9 8 field reserved port 2a diagnostic enable reserved port 1a diagnostic enable reserved... read/write - r/w - r/w - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved pull-down enable ls pull-up enable fs pull-up enable reserved force select read/write - r/w r/w r/w - r/w r/w r/w default 0 0 0 0 0 0 0 0 table 19. force select definition force select [2:0] data line state 1xx assert se0 01x toggle jk 001 assert j 000 assert k table 20. timer registers register name address r/w watchdog timer register 0xc00c r/w timer 0 register 0xc010 r/w timer 1 register 0xc012 r/w
cy7c67200 document number: 38-08014 rev. *j page 19 of 93 watchdog timer register [0xc00c] [r/w] figure 15. watchdog timer register register description the watchdog timer register prov ides status and control over the watchdog timer. the watchdog timer can also interrupt the processor. timeout flag (bit 5) the timeout flag bit indicates if the watchdog timer has expired. the processor can read this bit after exiting a reset to determine if a watchdog timeout occurred. this bit is cleared on the next external hardware reset. 1: watchdog timer expired 0: watchdog timer did not expire period select (bits [4:3]) the period select field is defined in table 21 . if this time expires before the reset strobe bit is set, the internal processor is reset. lock enable (bit 2) the lock enable bit does not allow any writes to this register until a reset. in doing so the watchdog timer can be set up and enabled permanently so that it can only be cleared on reset (the wdt enable bit is ignored). 1: watchdog timer permanently set 0: watchdog timer not permanently set wdt enable (bit 1) the wdt enable bit enables or disables the watchdog timer. 1: enable watchdog timer operation 0: disable watchdog timer operation reset strobe (bit 0) the reset strobe is a write-only bit that resets the watchdog timer count. it must be set to ?1? before the count expires to avoid a watchdog trigger 1: reset count reserved all reserved bits must be written as ?0?. bit # 15 14 13 12 11 10 9 8 field reserved... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved timeout flag period select lock enable wdt enable reset strobe read/write r/w r/w r/w r/w r/w r/w r/w w default 0 0 0 0 0 0 0 0 table 21. period select definition period select[4:3] wdt period value 00 1.4 ms 01 5.5 ms 10 22.0 ms 11 66.0 ms
cy7c67200 document number: 38-08014 rev. *j page 20 of 93 timer n register [r/w] timer 0 register 0xc010 timer 1 register 0xc012 figure 16. timer n register register description the timer n register sets the timer n count. both timer 0 and ti mer 1 decrement by one every 1-s clock tick. each can provide an interrupt to the cpu when the timer reaches zero. count (bits [15:0]) the count field sets the timer count. general usb registers [8] there is one set of registers dedicated to general usb control. this set consists of two identical registers, one for host/devi ce port 1 and one for host/device port 2. this register set has functi ons for both usb host and usb peripheral options and is covered i n this section and su mmarized in table 22 . usb host-only regist ers are covered in section ?usb host only registers? on page 22 and usb device-only registers are covered in section ?usb device only registers? on page 30 . usb n control register [r/w] usb 1 control register 0xc08a usb 2 control register 0xc0aa figure 17. usb n control register bit # 15 14 13 12 11 10 9 8 field count... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 1 1 1 1 1 1 1 1 bit # 7 6 5 4 3 2 1 0 field ...count read/write r/w r/w r/w r/w r/w r/w r/w r/w default 1 1 1 1 1 1 1 1 table 22. usb registers register name address (sie1/sie2) r/w usb n control register 0xc08a/0xc0aa r/w bit # 15 14 13 12 11 10 9 8 field reserved port a d+ status port a d? status reserved loa mode select reserved read/write - - r r - r/w r/w - default x x x x 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field port a resistors enable reserved port a force d state suspend enable reserved port a sof/eop enable read/write r/w - - r/w r/w r/w - r/w default 0 0 0 0 0 0 0 0 note 8. errata: writing to the sie2 control register via hpi can corrupt the sie1 control register. writing to the sie1 control register via h pi can corrupt the sie2 control register. for more information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 21 of 93 register description the usb n control register is used in both host and device mode. it monitors and controls the sie and the data lines of the usb ports. this register can be accessed by the hpi interface. port a d+ status (bit 13) the port a d+ status bit is a read -only bit that indicates the value of data+ on port a. 1: d+ is high 0: d+ is low port a d? status (bit 12) the port a d? status bit is a read-only bit that indicates the value of data? on port a. 1: d? is high 0: d? is low loa (bit 10) the loa bit selects the speed of port a. 1: port a is set to low-speed mode 0: port a is set to full-speed mode mode select (bit 9) the mode select bit sets the sie for host or device operation. when set for device operation only one usb port is supported. the active port is selected by the port select bit in the host n count register. 1: host mode 0: device mode port a resistors enable (bit 7) the port a resistors enable bit enables or disables the pull-up/pull-down resistors on port a. when enabled, the mode select bit and loa bit of this register sets the pull-up/pull-down resistors appropriately. when the mode select is set for host mode, the pull-down resistors on the data lines (d+ and d?) are enabled. when the mode select is set for device mode, a single pull-up resistor on either d+ or d?, determined by the loa bit, will be enabled. see ta b l e 2 3 for details. 1: enable pull-up/pull-down resistors 0: disable pull-up/pull-down resistors port a force d state (bits [4:3]) the port a force d state field c ontrols the forcing state of the d+ d? data lines for port a. this field forces the state of the port a data lines independent of the port select bit setting. see ta b l e 2 4 for details. suspend enable (bit 2) the suspend enable bit enables or disables the suspend feature on both ports. when suspend is enabled the usb transceivers are powered down and can not transmit or received usb packets but can still monitor for a wakeup condition. 1: enable suspend 0: disable suspend port a sof/eop enable (bit 0) the port a sof/eop enable bit is only applicable in host mode. in device mode this bit must be written as ?0?. in host mode this bit enables or disables sofs or eops for port a. either sofs or eops will be generated depending on the loa bit in the usb n control register when port a is active. 1: enable sofs or eops 0: disable sofs or eops reserved all reserved bits must be written as ?0?. table 23. usb data line pull-up and pull-down resistors l0a mode select port n resistors enable function x x 0 pull up/pull down on d+ and d? disabled x 1 1 pull down on d+ and d? enabled 1 0 1 pull up on usb d? enabled 0 0 1 pull up on usb d+ enabled table 24. port a force d state port a force d state function msb lsb 0 0 normal operation 0 1 force usb reset, se0 state 1 0 force j-state 1 1 force k-state
cy7c67200 document number: 38-08014 rev. *j page 22 of 93 usb host only registers there are twelve sets of dedicated registers to usb host only oper ation. each set consists of two identical registers (unless o therwise noted); one for host port 1 and one for host port 2. these re gister sets are covered in this section and summarized in ta b l e 2 5 . host n control register [r/w] host 1 control register 0xc080 host 2 control register 0xc0a0 figure 18. host n control register table 25. usb host only register register name address (host 1/host 2) r/w host n control regist er 0xc080/0xc0a0 r/w host n address register 0xc082/0xc0a2 r/w host n count regist er 0xc084/0xc0a4 r/w host n endpoint status register 0xc086/0xc0a6 r host n pid register 0xc086/0xc0a6 w host n count result register 0xc088/0xc0a8 r host n device address register 0xc088/0xc0a8 w host n interrupt enable register 0xc08c/0xc0ac r/w host n status register 0xc090/0xc0b0 r/w host n sof/eop count re gister 0xc092/0xc0b2 r/w host n sof/eop counter register 0xc094/0xc0b4 r host n frame register 0xc096/0xc0b6 r bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field preamble enable sequence select sync enable iso enable reserved arm enable read/write r/w r/w r/w r/w - - - r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 23 of 93 register description the host n control register allows high-level usb transaction control. preamble enable (bit 7) the preamble enable bit enables or disables the transmission of a preamble packet before all low-speed packets. this bit should only be set when communicating with a low-speed device. 1: enable preamble packet 0: disable preamble packet sequence select (bit 6) the sequence select bit sets the data toggle for the next packet. this bit has no effect on receiving data packets; sequence checking must be handled in firmware. 1: send data1 0: send data0 sync enable (bit 5) the sync enable bit synchronizes the transfer with the sof packet in full-speed mode and the eop packet in low-speed mode. 1: the next enabled packet will be transferred after the sof or eop packet is transmitted 0: the next enabled packet will be transferred as soon as the sie is free iso enable (bit 4) the iso enable bit enables or disables an isochronous trans- action. 1: enable isochronous transaction 0: disable isochronous transaction arm enable (bit 0) the arm enable bit arms an endpoint and starts a transaction. this bit is automatically cleared to ?0? when a transaction is complete. 1: arm endpoint and begin transaction 0: endpoint disarmed reserved all reserved bits must be written as ?0?. host n address register [r/w] host 1 address register 0xc082 host 2 address register 0xc0a2 figure 19. host n address register register description the host n address register is used as the base pointer into memory space for the curr ent host transactions. address (bits [15:0]) the address field sets the address pointer into internal ram or rom. bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 24 of 93 host n count register [r/w] host 1 count register 0xc084 host 2 count register 0xc0a4 figure 20. host n count register register description the host n count register is us ed to hold the number of bytes (packet length) for the current transaction. the maximum packet length is 1023 bytes in iso mode. the host count value is used to determine how many bytes to transmit, or the maximum number of bytes to receive. if the number of received bytes is greater then the host count value then an overflow condition will be flagged by the overflow bit in the host n endpoint status register. count (bits [9:0]) the count field sets the value for the current transaction data packet length. this value is retained when switching between host and device mode, and back again. reserved all reserved bits must be written as ?0?. host n endpoint status register [r] host 1 endpoint status register 0xc086 host 2 endpoint status register 0xc0a6 figure 21. host n endpoint status register register description the host n endpoint status regist er is a read-only register that provides status for the last usb transaction. overflow flag (bit 11) the overflow flag bit indicates that the received data in the last data transaction exceeded the ma ximum length specified in the host n count register. the overflow flag should be checked in response to a length exception signified by the length exception flag set to ?1?. 1: overflow condition occurred 0: overflow condition did not occur underflow flag (bit 10) the underflow flag bit indicates that the received data in the last data transaction was less then the maximum length specified in the host n count register. the underflow flag should be checked in response to a length exception signified by the length exception flag set to ?1?. 1: underflow condition occurred 0: underflow condition did not occur bit # 15 14 13 12 11 10 9 8 field reserved count... read/write - - - - - - r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...count read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved overflow flag underflow flag reserved read/write - - - - r r - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field stall flag nak flag length exception flag reserved sequence status timeout flag error flag ack flag read/write r r r - r r r r default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 25 of 93 stall flag (bit 7) the stall flag bit indicates that the peripheral device replied with a stall in the last transaction. 1: device returned stall 0: device did not return stall nak flag (bit 6) the nak flag bit indicates that the peripheral device replied with a nak in the last transaction. 1: device returned nak 0: device did not return nak length exception flag (bit 5) the length exception flag bit indicates the received data in the data stage of the last transaction does not equal the maximum host count specified in the host n count register. a length exception can either mean an overflow or underflow and the overflow and underflow flags (bits 11 and 10, respectively) should be checked to determine which event occurred. 1: an overflow or underflow condition occurred 0: an overflow or underflow condition did not occur sequence status (bit 3) the sequence status bit indicates the state of the last received data toggle from the device. firmware is responsible for monitoring and handling the sequence status. the sequence bit is only valid if the ack bit is set to ?1?. the sequence bit is set to ?0? when an error is detected in the transaction and the error bit will be set. 1: data1 0: data0 timeout flag (bit 2) the timeout flag bit indicates if a timeout condition occurred for the last transaction. a timeout condition can occur when a device either takes too long to respond to a usb host request or takes too long to respond with a handshake. 1: timeout occurred 0: timeout did not occur error flag (bit 1) the error flag bit indicates a transaction failed for any reason other than the following: timeout, receiving a nak, or receiving a stall. overflow and underflow are not considered errors and do not affect this bit. crc5 and crc16 errors will result in an error flag along with receiving incorrect packet types. 1: error detected 0: no error detected ack flag (bit 0) the ack flag bit indicates two different conditions depending on the transfer type. for non-isochronous transfers, this bit repre- sents a transaction ending by receiving or sending an ack packet. for isochronous transfers, this bit represents a successful transaction that will not be represented by an ack packet. 1: for non-isochronous transfers, the transaction was acked. for isochronous transfers, th e transaction was completed successfully. 0: for non-isochronous transfer s, the transaction was not acked. for isochronous transfers, the transaction was not completed successfully. host n pid register [w] host 1 pid register 0xc086 host 2 pid register 0xc0a6 figure 22. host n pid register bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field pid select endpoint select read/write w w w w w w w w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 26 of 93 register description the host n pid register is a write- only register that provides the pid and endpoint information to the usb sie to be used in the next transaction. pid select (bits [7:4]) the pid select field defined as in table 26 . ack and nak tokens are automatically sent based on settings in the host n control register and do not need to be written in this register. endpoint select (bits [3:0]) the endpoint field allows addressing of up to 16 different endpoints. reserved all reserved bits must be written as ?0?. host n count result register [r] host 1 count result register 0xc088 host 2 count result register 0xc0a8 figure 23. host n count result register register description the host n count result register is a read-only register that contains the size difference in bytes between the host count value specified in the host n co unt register and the last packet received. if an overflow or underflo w condition occurs, that is the received packet length differs from the value specified in the host n count register, the length exce ption flag bit in the host n endpoint status register will be set. the value in this register is only valid when the length exception flag bit is set and the error flag bit is not set; both bits ar e in the host n endpoint status register. result (bits [15:0]) the result field contains the differences in bytes between the received packet and the value specified in the host n count register. if an overflow condition occurs, result [15:10] is set to ?111111?, a 2?s complement value indicating the additional byte count of the received packet. if an underflow condition occurs, result [15:0] indicates the exce ss byte count (number of bytes not used). reserved all reserved bits must be written as ?0?. table 26. pid select definition pid type pid select [7:4] set-up 1101 (d hex) in 1001 (9 hex) out 0001 (1 hex) sof 0101 (5 hex) preamble 1100 (c hex) nak 1010 (a hex) stall 1110 (e hex) data0 0011 (3 hex) data1 1011 (b hex) table 26. pid select definition (continued) pid type pid select [7:4] bit # 15 14 13 12 11 10 9 8 field result... read/write r r r r r r r r default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...result read/write r r r r r r r r default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 27 of 93 host n device addr ess register [w] host 1 device address register 0xc088 host 2 device address register 0xc0a8 figure 24. host n device address register register description the host n device address register is a write-only register that contains the usb device address that the host wishes to communicate with. address (bits [6:0]) the address field contains the value of the usb address for the next device that the host is going to communicate with. this value must be written by firmware. reserved all reserved bits must be written as ?0?. host n interrupt enable register [r/w] host 1 interrupt enable register 0xc08c host 2 interrupt enable register 0xc0ac figure 25. host n interrupt enable register register description the host n interrupt enable register allows control over host-related interrupts. in this register a bit set to ?1? enables the corresponding interrupt while ?0? disables the interrupt. vbus interrupt enable (bit 15) the vbus interrupt enable bit enables or disables the otg vbus interrupt. when enabled this interrupt triggers on both the rising and falling edge of vbus at the 4.4 v status (only supported in port 1a). this bit is only available for host 1 and is a reserved bit in host 2. 1: enable vbus interrupt 0: disable vbus interrupt id interrupt enable (bit 14) the id interrupt enable bit enables or disables the otg id interrupt. when enabled this interrupt triggers on both the rising and falling edge of the otg id pin (only supported in port 1a). this bit is only available for host 1 and is a reserved bit in host 2. 1: enable id interrupt 0: disable id interrupt sof/eop interrupt enable (bit 9) the sof/eop interrupt enable bit enables or disables the sof/eop timer interrupt. bit # 15 14 13 12 11 10 9 8 field reserved... read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved address read/write - w w w w w w w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field vbus interrupt enable id interrupt enable reserved sof/eop interrupt enable reserved read/write r/w r/w - - - - r/w - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field reserved port a wake interrupt enable reserved port a connect change interrupt enable reserved done interrupt enable read/write - r/w - r/w - - - r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 28 of 93 1: enable sof/eop timer interrupt 0: disable sof/eop timer interrupt port a wake interrupt enable (bit 6) the port a wake interrupt enable bit enables or disables the remote wakeup inte rrupt for port a. 1: enable remote wakeup interrupt for port a 0: disable remote wakeup interrupt for port a port a connect change interrupt enable (bit 4) the port a connect change interrupt enable bit enables or disables the connect change interr upt on port a. this interrupt triggers when either a device is in serted (se0 state to j state) or a device is removed (j state to se0 state). 1: enable connect change interrupt 0: disable connect change interrupt done interrupt enable (bit 0) the done interrupt enable bit enables or disables the usb transfer done interrupt. the usb transfer done triggers when either the host responds with an ack, or a device responds with any of the following: ack, n ak, stall, or timeout. this interrupt is used for both port a and port b. 1: enable usb transfer done interrupt 0: disable usb transfer done interrupt reserved all reserved bits must be written as ?0?. host n status register [r/w] host 1 status register 0xc090 host 2 status register 0xc0b0 figure 26. host n status register register description the host n status register prov ides status information for host operation. pending interrupts can be cleared by writing a ?1? to the corresponding bit. this register can be accessed by the hpi interface. vbus interrupt flag (bit 15) the vbus interrupt flag bit indicates the status of the otg vbus interrupt (only for port 1a). when enabled this interrupt triggers on both the rising and falling edge of vbus at 4.4 v. this bit is only available for host 1 and is a reserved bit in host 2. 1: interrupt triggered 0: interrupt did not trigger id interrupt flag (bit 14) the id interrupt flag bit indicates the status of the otg id interrupt (only for port 1a). when enabled this interrupt triggers on both the rising and falling edge of the otg id pin. this bit is only available for host 1 and is a reserved bit in host 2. 1: interrupt triggered 0: interrupt did not trigger sof/eop interrupt flag (bit 9) the sof/eop interrupt flag bit indicates the status of the sof/eop timer interrupt. this bit triggers ?1? when the sof/eop timer expires. 1: interrupt triggered 0: interrupt did not trigger bit # 15 14 13 12 11 10 9 8 field vbus interrupt flag id interrupt flag reserved sof/eop interrupt flag reserved read/write r/w r/w - - - - r/w - default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field reserved port a wake interrupt flag reserved port a connect change interrupt flag reserved port a se0 status reserved done interrupt flag read/write - r/w - r/w - r/w - r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 29 of 93 port a wake interrupt flag (bit 6) the port a wake interrupt flag bit indicates remote wakeup on port a. 1: interrupt triggered 0: interrupt did not trigger port a connect change interrupt flag (bit 4) the port a connect change interrupt flag bit indicates the status of the connect change in terrupt on port a. this bit triggers ?1? on either a rising edge or falling edge of a usb reset condition (device inserted or re moved). together with the port a se0 status bit, it can be determined whether a device was inserted or removed. 1: interrupt triggered 0: interrupt did not trigger port a se0 status (bit 2) the port a se0 status bit indicates if port a is in an se0 state or not. together with the port a c onnect change interrupt flag bit, it can be determined whether a device was inserted (non-se0 condition) or removed (se0 condition). 1: se0 condition 0: non-se0 condition done interrupt flag (bit 0) the done interrupt flag bit indicates the status of the usb transfer done interrupt. the usb transfer done triggers when either the host responds with an ack, or a device responds with any of the following: ack, n ak, stall, or timeout. this interrupt is used for both port a and port b. 1: interrupt triggered 0: interrupt did not trigger host n sof/eop count register [r/w] host 1 sof/eop count register 0xc092 host 2 sof/eop count register 0xc0b2 figure 27. host n sof/eop count register register description the host n sof/eop count regi ster contains the sof/eop count value that is loaded into the sof/eop counter. this value is loaded each time the sof/eop counter counts down to zero. the default value set in this register at power-up is 0x2ee0, which will generate a 1-ms time frame. the sof/eop counter is a down counter decremented at a 12-mhz rate. when this register is read, the value returned is the programmed sof/eop count value. count (bits [13:0]) the count field sets the sof/eop counter duration. reserved all reserved bits must be written as ?0?. bit # 15 14 13 12 11 10 9 8 field reserved count... read/write - - r/w r/w r/w r/w r/w r/w default 0 0 1 0 1 1 1 0 bit # 7 6 5 4 3 2 1 0 field ...count read/write r/w r/w r/w r/w r/w r/w r/w r/w default 1 1 1 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 30 of 93 host n sof/eop counter register [r] host 1 sof/eop counter register 0xc094 host 2 sof/eop counter register 0xc0b4 figure 28. host n sof/eop counter register register description the host n sof/eop counter regist er contains the current value of the sof/eop down counter. this value can be used to determine the time remaining in the current frame. counter (bits [13:0]) the counter field contains the current value of the sof/eop down counter. host n frame register [r] host 1 frame register 0xc096 host 2 frame register 0xc0b6 figure 29. host n frame register register description the host n frame register maintains the next frame number to be transmitted (current frame number + 1). this value is updated after each sof transmission. this register resets to 0x0000 after each cpu write to the host n sof/eop count register (host 1: 0xc092, host 2: 0xc0b2). frame (bits [10:0]) the frame field contains the next frame number to be trans- mitted. reserved all reserved bits must be written as ?0?. usb device only registers there are ten sets of usb device only registers. all sets consist of at least two registers, one for device port 1 and one for device port 2. in addition, each device port has eight possible endpoints. this gives each endpoi nt register set eight registers for each device port for a total of 16 registers per set. the usb device only registers are cove red in this section and summa- rized in table 27 . bit # 15 14 13 12 11 10 9 8 field reserved counter... read/write - - r r r r r r default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ...counter read/write r r r r r r r r default x x x x x x x x bit # 15 14 13 12 11 10 9 8 field reserved frame... read/write - - - - - r r r default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...frame read/write r r r r r r r r default 0 0 0 0 0 0 0 0 table 27. usb device only registers register name address (device 1/device 2) r/w device n endpoint n control register 0x02n0 r/w device n endpoint n address register 0x02n2 r/w
cy7c67200 document number: 38-08014 rev. *j page 31 of 93 device n endpoint n control register [r/w] device n endpoint 0 control register [device 1: 0x0200 device 2: 0x0280] device n endpoint 1 control register [device 1: 0x0210 device 2: 0x0290] device n endpoint 2 control register [device 1: 0x0220 device 2: 0x02a0] device n endpoint 3 control register [device 1: 0x0230 device 2: 0x02b0] device n endpoint 4 control register [device 1: 0x0240 device 2: 0x02c0] device n endpoint 5 control register [device 1: 0x0250 device 2: 0x02d0] device n endpoint 6 control register [device 1: 0x0260 device 2: 0x02e0] device n endpoint 7 control register [device 1: 0x0270 device 2: 0x02f0] figure 30. device n endpoint n control register register description the device n endpoint n control r egister provides control over a single ep in device mode. there are a total of eight endpoints for each of the two ports. all endpoi nts have the same definition for their device n endpoint n control register. in/out ignore enable (bit 6) the in/out ignore enable bit forces endpoint 0 (ep0) to ignore all in and out requests. this bit must be set so that ep0 only excepts setup packets at the start of each transfer. this bit must be cleared to except in/out transactions. this bit only applies to ep0. 1: ignore in/out requests 0: do not ignore in/out requests sequence select (bit 6) the sequence select bit determines whether a data0 or a data1 will be sent for the next dat a toggle. this bit has no effect on receiving data packets, sequence checking must be handled in firmware. 1: send a data1 0: send a data0 stall enable (bit 5) the stall enable bit sends a stall in response to the next request (unless it is a setup request, which are always acked). this is a sticky bit and continues to respond with stalls until cleared by firmware. 1: send stall device n endpoint n count register 0x02n4 r/w device n endpoint n status register 0x02n6 r/w device n endpoint n count result register 0x02n8 r/w device n interrupt enable register 0xc08c/0xc0ac r/w device n address register 0xc08e/0xc0ae r/w device n status register 0xc090/0xcb0 r/w device n frame number register 0xc092/0xc0b2 r device n sof/eop count register 0xc094/0xc0b4 w table 27. usb device only registers (continued) register name address (device 1/device 2) r/w bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field in/out ignore enable sequence select stall enable iso enable nak interrupt enable direction select enable arm enable read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 32 of 93 0: do not send stall iso enable (bit 4) the iso enable bit enables and disables an isochronous trans- action. this bit is only valid for eps 1?7 and has no function for ep0. 1: enable isochronous transaction 0: disable isochronous transaction nak interrupt enable (bit 3) the nak interrupt enable bit enables and disables the gener- ation of an endpoint n interrupt when the device responds to the host with a nak. the endpoint n interrupt enable bit in the device n interrupt enable register must also be set. when a nak is sent to the host, the corresponding ep interrupt flag in the device n status register will be set. in addition, the nak flag in the device n endpoint n status register will be set. 1: enable nak interrupt 0: disable nak interrupt direction select (bit 2) the direction select bit need s to be set according to the expected direction of the next dat a stage in the next transaction. if the data stage direction is different from what is set in this bit, it will get naked and either the in exception flag or the out exception flag will be set in the device n endpoint n status register. if a setup packet is received and the direction select bit is set incorrectly, the setup will be acked and the set-up status flag will be set (refer to the setup bit of the device n endpoint n status register for details). 1: out transfer (host to device) 0: in transfer (device to host) enable (bit 1) the enable bit must be set to allow transfers to the endpoint. if enable is set to ?0? then all usb traffic to this endpoint is ignored. if enable is set ?1? and arm enable (bit 0) is set ?0? then naks will automatically be returned from this endpoint (except setup packets, which are always acked as long as the enable bit is set). 1: enable transfers to an endpoint 0: do not allow transfers to an endpoint arm enable (bit 0) the arm enable bit arms the endpoint to transfer or receive a packet. this bit is cleared to ?0? when a transaction is complete. 1: arm endpoint 0: endpoint disarmed reserved all reserved bits must be written as ?0?. device n endpoint n address register [r/w] device n endpoint 0 address register [device 1: 0x0202 device 2: 0x0282] device n endpoint 1 address register [device 1: 0x0212 device 2: 0x0292] device n endpoint 2 address register [device 1: 0x0222 device 2: 0x02a2] device n endpoint 3 address register [device 1: 0x0232 device 2: 0x02b2] device n endpoint 4 address register [device 1: 0x0242 device 2: 0x02c2] device n endpoint 5 address register [device 1: 0x0252 device 2: 0x02d2] device n endpoint 6 address register [device 1: 0x0262 device 2: 0x02e2] device n endpoint 7 address register [device 1: 0x0272 device 2: 0x02f2] figure 31. device n endpoint n address register bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 33 of 93 register description the device n endpoint n address register is used as the base pointer into memory space for th e current endpoint transaction. th ere are a total of eight endpoints for each of the two ports. all endpoints have the same definition for their device n endpoint n address register. address (bits [15:0]) the address field sets the base address for t he current transaction on a signal endpoint. device n endpoint n count register [r/w] device n endpoint 0 count register [device 1: 0x0204 device 2: 0x0284] device n endpoint 1 count register [device 1: 0x0214 device 2: 0x0294] device n endpoint 2 count register [device 1: 0x0224 device 2: 0x02a4] device n endpoint 3 count register [device 1: 0x0234 device 2: 0x02b4] device n endpoint 4 count register [device 1: 0x0244 device 2: 0x02c4] device n endpoint 5 count register [device 1: 0x0254 device 2: 0x02d4] device n endpoint 6 count register [device 1: 0x0264 device 2: 0x02e4] device n endpoint 7 count register [device 1: 0x0274 device 2: 0x02f4] figure 32. device n endpoint n count register bit # 15 14 13 12 11 10 9 8 field reserved count... read/write - - - - - - r/w r/w default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ...count read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 34 of 93 register description the device n endpoint n count register desi gnates the maximum packet size that can be received from the host for out transfers for a single endpoint. this register also designates the packet si ze to be sent to the host in response to the next in token fo r a single endpoint. the maximum packet length is 1023 bytes in iso mode. there are a total of eight endpoi nts for each of the two ports. all endpoints have the same definition for their device n endpoint n count register. count (bits [9:0]) the count field sets the current transaction packet length for a single endpoint. reserved all reserved bits must be written as ?0?. device n endpoint n status register [r/w] device n endpoint 0 status register [device 1: 0x0206 device 2: 0x0286] device n endpoint 1 status register [device 1: 0x0216 device 2: 0x0296] device n endpoint 2 status register [device 1: 0x0226 device 2: 0x02a6] device n endpoint 3 status register [device 1: 0x0236 device 2: 0x02b6] device n endpoint 4 status register [device 1: 0x0246 device 2: 0x02c6] device n endpoint 5 status register [device 1: 0x0256 device 2: 0x02d6] device n endpoint 6 status register [device 1: 0x0266 device 2: 0x02e6] device n endpoint 7 status register [device 1: 0x0276 device 2: 0x02f6] figure 33. device n endpoint n status register register description the device n endpoint n status register provides packet status information for the last transaction received or transmitted. this register is updated in hardware and does not need to be cleared by firmware. there are a total of eight endpoints for each of the two ports. all endpoints have the same definition for their device n endpoint n status register. the device n endpoint n status register is a memory-based register that must be initialized to 0x0000 before usb device operations are initiated. after init ialization, this register must not be written to again. overflow flag (bit 11) the overflow flag bit indicates that the received data in the last data transaction exceeded the ma ximum length specified in the device n endpoint n count register. the overflow flag should be checked in response to a length exception signified by the length exception flag set to ?1?. 1: overflow condition occurred 0: overflow condition did not occur underflow flag (bit 10) the underflow flag bit indicates that the received data in the last data transaction was less then the maximum length specified in the device n endpoint n count register. the underflow flag should be checked in response to a length exception signified by the length exception flag set to ?1?. 1: underflow condition occurred 0: underflow condition did not occur out exception flag (bit 9) the out exception flag bit indicates when the device received an out packet when armed for an in. 1: received out when armed for in 0: received in when armed for in bit # 15 14 13 12 11 10 9 8 field reserved overflow flag underflow flag out exception flag in exception flag read/write - - - - r/w r/w r/w r/w default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field stall flag nak flag length exception flag setup flag sequence flag timeout flag error flag ack flag read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 35 of 93 i n exception flag (bit 8) the in exception flag bit indicates when the device received an in packet when armed for an out. 1: received in when armed for out 0: received out when armed for out stall flag (bit 7) the stall flag bit indicates that a stall packet was sent to the host. 1: stall packet was sent to the host 0: stall packet was not sent nak flag (bit 6) the nak flag bit indicates that a nak packet was sent to the host. 1: nak packet was sent to the host 0: nak packet was not sent length exception flag (bit 5) the length exception flag bit indicates the received data in the data stage of the last transaction does not equal the maximum endpoint count specified in the device n endpoint n count register. a length exception can either mean an overflow or underflow and the overflow and underflow flags (bits 11 and 10, respectively) should be checked to determine which event occurred. 1: an overflow or underflow condition occurred 0: an overflow or underflow condition did not occur setup flag (bit 4) the setup flag bit indicates that a setup packet was received. in device mode setup packets are stored at memory location 0x0300 for device 1 and 0x0308 for device 2. setup packets are always accepted regardless of the direction select and arm enable bit settings as long as the device n ep n control register enable bit is set. 1: setup packet was received 0: setup packet was not received sequence flag (bit 3) the sequence flag bit indicates whether the last data toggle received was a data1 or a data0. this bit has no effect on receiving data packets; sequence checking must be handled in firmware. 1: data1 was received 0: data0 was received timeout flag (bit 2) the timeout flag bit indicates whether a timeout condition occurred on the last transaction. on the device side, a timeout can occur if the device sends a data packet in response to an in request but then does not receive a handshake packet in a predetermined time. it can also occur if the device does not receive the data stage of an out transfer in time. 1: timeout occurred 0: timeout condition did not occur error flag (bit 2) the error flag bit is set if a crc5 and crc16 error occurs, or if an incorrect packet type is received. overflow and underflow are not considered errors and do not affect this bit. 1: error occurred 0: error did not occur ack flag (bit 0) the ack flag bit indicates whether the last transaction was acked. 1: ack occurred 0: ack did not occur
cy7c67200 document number: 38-08014 rev. *j page 36 of 93 device n endpoint n count result register [r/w] device n endpoint 0 count result register [device 1: 0x0208 device 2: 0x0288] device n endpoint 1 count result register [device 1: 0x0218 device 2: 0x0298] device n endpoint 2 count result register [device 1: 0x0228 device 2: 0x02a8] device n endpoint 3 count result register [device 1: 0x0238 device 2: 0x02b8] device n endpoint 4 count result register [device 1: 0x0248 device 2: 0x02c8] device n endpoint 5 count result register [device 1: 0x0258 device 2: 0x02d8] device n endpoint 6 count result register [device 1: 0x0268 device 2: 0x02e8] device n endpoint 7 count result register [device 1: 0x0278 device 2: 0x02f8] figure 34. device n endpoint n count result register register description the device n endpoint n count result register contains the size difference in bytes between the endpoint count specified in the device n endpoint n count register and the last packet received. if an overflow or underflow condition occurs, that is the received packet length differs from the value specified in the device n endpoint n count register, the length exception flag bit in the device n endpoint n status register will be set. the value in this register is only considered when the length exception flag bit is set and the error flag bit is not set; both bits are in the device n endpoint n status register. the device n endpoint n count result register is a memory based register that must be initialized to 0x0000 before usb device operations are initiated. af ter initialization, this register must not be written to again. result (bits [15:0]) the result field contains the differences in bytes between the received packet and the value specified in the device n endpoint n count register. if an overflow condition occurs, result [15:10] is set to ?111111?, a 2?s comp lement value indicating the additional byte count of the received packet. if an underflow condition occurs, result [15:0] indicates the excess byte count (number of bytes not used). reserved all reserved bits must be written as ?0?. bit # 15 14 13 12 11 10 9 8 field result... read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ...result read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 37 of 93 device n interrupt enable register [r/w] device 1 interrupt enable register 0xc08c device 2 interrupt enable register 0xc0ac figure 35. device n interrupt enable register register description the device n interrupt enable register provides control over device-related interrupts including eight different endpoint inter- rupts. vbus interrupt enable (bit 15) the vbus interrupt enable bit enables or disables the otg vbus interrupt. when enabled this interrupt triggers on both the rising and falling edge of vbus at the 4.4 v status (only supported in port 1a). this bit is only available for device 1 and is a reserved bit in device 2. 1: enable vbus interrupt 0: disable vbus interrupt id interrupt enable (bit 14) the id interrupt enable bit enables or disables the otg id interrupt. when enabled this interrupt triggers on both the rising and falling edge of the otg id pin (only supported in port 1a). this bit is only available for device 1 and is a reserved bit in device 2. 1: enable id interrupt 0: disable id interrupt sof/eop timeout interrupt enable (bit 11) the sof/eop timeout interrupt e nable bit enables or disables the sof/eop timeout interrupt. when enabled this interrupt triggers when the usb host fails to send a sof or eop packet within the time period specified in the device n sof/eop count register. in addition, the device n frame register counts the number of times the sof/eop timeout interrupt triggers between receiving sof/eops. 1: sof/eop timeout occurred 0: sof/eop timeout did not occur sof/eop interrupt enable (bit 9) the sof/eop interrupt enable bit enables or disables the sof/eop received interrupt. 1: enable sof/eop received interrupt 0: disable sof/eop received interrupt reset interrupt enable (bit 8) the reset interrupt enable bit enables or disables the usb reset detected interrupt 1: enable usb reset detected interrupt 0: disable usb reset detected interrupt ep7 interrupt enable (bit 7) the ep7 interrupt enable bit enables or disables an endpoint seven (ep7) transaction done interrupt. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak response s triggers this interrupt. 1: enable ep7 transaction done interrupt 0: disable ep7 transaction done interrupt ep6 interrupt enable (bit 6) the ep6 interrupt enable bit enables or disables an endpoint six (ep6) transaction done interrupt. an epx transaction done interrupt triggers when any of t he following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak response s triggers this interrupt. 1: enable ep6 transaction done interrupt 0: disable ep6 transaction done interrupt bit # 15 14 13 12 11 10 9 8 field vbus interrupt enable id interrupt enable reserved sof/eop timeout interrupt enable reserved sof/eop interrupt enable reset interrupt enable read/write r/w r/w - - r/w - r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ep7 interrupt enable ep6 interrupt enable ep5 interrupt enable ep4 interrupt enable ep3 interrupt enable ep2 interrupt enable ep1 interrupt enable ep0 interrupt enable read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 38 of 93 ep5 interrupt enable (bit 5) the ep5 interrupt enable bit enables or disables an endpoint five (ep5) transaction done interrupt. an epx transaction done interrupt triggers when any of th e following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak responses triggers this interrupt. 1: enable ep5 transaction done interrupt 0: disable ep5 transaction done interrupt ep4 interrupt enable (bit 4) the ep4 interrupt enable bit enables or disables an endpoint four (ep4) transaction done interrupt. an epx transaction done interrupt triggers when any of th e following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak responses triggers this interrupt. 1: enable ep4 transaction done interrupt 0: disable ep4 transaction done interrupt ep3 interrupt enable (bit 3) the ep3 interrupt enable bit enables or disables an endpoint three (ep3) transaction done interrupt. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak responses triggers this interrupt. 1: enable ep3 transaction done interrupt 0: disable ep3 transaction done interrupt ep2 interrupt enable (bit 2) the ep2 interrupt enable bit enables or disables an endpoint two (ep2) transaction done interrupt. an epx transaction done interrupt triggers when any of t he following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak response s triggers this interrupt. 1: enable ep2 transaction done interrupt 0: disable ep2 transaction done interrupt ep1 interrupt enable (bit 1) the ep1 interrupt enable bit enables or disables an endpoint one (ep1) transaction done interrupt. an epx transaction done interrupt triggers when any of t he following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak response s triggers this interrupt. 1: enable ep1 transaction done interrupt 0: disable ep1 transaction done interrupt ep0 interrupt enable (bit 0) the ep0 interrupt enable bit enables or disables an endpoint zero (ep0) transaction done interrupt. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given endpoint: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, the nak interrupt enable bit in the device n endpoint control register can also be set so that nak response s triggers this interrupt. 1: enable ep0 transaction done interrupt 0: disable ep0 transaction done interrupt reserved all reserved bits must be written as ?0?.
cy7c67200 document number: 38-08014 rev. *j page 39 of 93 device n address register [w] device 1 address register 0xc08e device 2 address register 0xc0ae figure 36. device n address register register description the device n address register holds the device address assigned by the host. this register initializes to the default address 0 at reset but must be updated by firmware when the host assigns a new address. only usb data sent to the address contained in this regist er will be responded to, all others are ignored. address (bits [6:0]) the address field contains the usb address of the device assigned by the host. reserved all reserved bits must be written as ?0?. device n status register [r/w] device 1 status register 0xc090 device 2 status register 0xc0b0 figure 37. device n status register register description the device n status register provides status information for device operation. pending interrupts can be cleared by writing a ?1? to the corresponding bit. this register can be accessed by the hpi interface. vbus interrupt flag (bit 15) the vbus interrupt flag bit indicates the status of the otg vbus interrupt (only for port 1a). when enabled this interrupt triggers on both the rising and falling edge of vbus at 4.4 v. this bit is only available for device 1 and is a reserved bit in device 2. 1: interrupt triggered 0: interrupt did not trigger id interrupt flag (bit 14) the id interrupt flag bit indicates the status of the otg id interrupt (only for port 1a). when enabled this interrupt triggers on both the rising and falling edge of the otg id pin. this bit is only available for device 1 and is a reserved bit in device 2. 1: interrupt triggered 0: interrupt did not trigger sof/eop interrupt flag (bit 9) the sof/eop interrupt flag bi t indicates if the sof/eop received interrupt has triggered. 1: interrupt triggered bit # 15 14 13 12 11 10 9 8 field reserved... read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved address read/write - w w w w w w w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field vbus interrupt flag id interrupt flag reserved sof/eop interrupt flag reset interrupt flag read/write r/w r/w - - - - r/w r/w default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ep7 interrupt flag ep6 interrupt flag ep5 interrupt flag ep4 interrupt flag ep3 interrupt flag ep2 interrupt flag ep1 interrupt flag ep0 interrupt flag read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 40 of 93 0: interrupt did not trigger reset interrupt flag (bit 8) the reset interrupt flag bit indicates if the usb reset detected interrupt has triggered. 1: interrupt triggered 0: interrupt did not trigger ep7 interrupt flag (bit 7) the ep7 interrupt flag bit indicates if the endpoint seven (ep7) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep6 interrupt flag (bit 6) the ep6 interrupt flag bit indicates if the endpoint six (ep6) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep5 interrupt flag (bit 5) the ep5 interrupt flag bit indicates if the endpoint five (ep5) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep4 interrupt flag (bit 4) the ep4 interrupt flag bit indicates if the endpoint four (ep4) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep3 interrupt flag (bit 3) the ep3 interrupt flag bit indicates if the endpoint three (ep3) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep2 interrupt flag (bit 2) the ep2 interrupt flag bit indicates if the endpoint two (ep2) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep1 interrupt flag (bit 1) the ep1 interrupt flag bit indicates if the endpoint one (ep1) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger ep0 interrupt flag (bit 0) the ep0 interrupt flag bit indicates if the endpoint zero (ep0) transaction done interrupt has triggered. an epx transaction done interrupt triggers when any of the following responses or events occur in a transaction for the device?s given ep: send/receive ack, send stall, timeout occurs, in exception error, or out exception error. in addition, if the nak interrupt enable bit in the device n endpoint control register is set, this interrupt also triggers when the device naks host requests. 1: interrupt triggered 0: interrupt did not trigger reserved all reserved bits must be written as ?0?.
cy7c67200 document number: 38-08014 rev. *j page 41 of 93 device n frame number register [r] device 1 frame number register 0xc092 device 2 frame number register 0xc0b2 figure 38. device n frame number register register description the device n frame number register is a read only register that contains the frame number of the last sof packet received. this register also contains a count of sof/eop timeout occurrences. sof/eop timeout flag (bit 15) the sof/eop timeout flag bit indicates when an sof/eop timeout interrupt occurs. 1: an sof/eop timeout interrupt occurred 0: an sof/eop timeout interrupt did not occur sof/eop timeout interrupt counter (bits [14:12]) the sof/eop timeout interrupt counter field increments by 1 from 0 to 7 for each sof/eop time out interrupt. this field resets to 0 when a sof/eop is received. this field is only updated when the sof/eop timeout interrupt enable bit in the device n interrupt enable register is set. frame (bits [10:0]) the frame field contains the frame number from the last received sof packet in full speed mode. this field has no function for low-speed mode. if a sof timeout occurs, this field contains the last received frame number. device n sof/eop count register [w] device 1 sof/eop count register 0xc094 device 2 sof/eop c ount register 0xc0b4 figure 39. device n sof/eop count register bit # 15 14 13 12 11 10 9 8 field sof/eop timeout flag sof/eop timeout interrupt counter reserved frame... read/write r r r r - r r r default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...frame read/write r r r r r r r r default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved count... read/write - - r r r r r r default 0 0 1 0 1 1 1 0 bit # 7 6 5 4 3 2 1 0 field ...count read/write r r r r r r r r default 1 1 1 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 42 of 93 register description the device n sof/eop count regi ster must be written with the time expected between receivi ng a sof/eops. if the sof/eop counter expires before an sof/eop is received, an sof/eop timeout interrupt can be generated. the sof/eop timeout interrupt enable and sof/eop timeout interrupt flag are located in the device n interrupt enable and status registers, respectively. the sof/eop count must be set slightly greater than the expected sof/eop interval. the sof/eop counter decrements at a 12-mhz rate. therefore in the case of an expected 1-ms sof/eop interval, the sof/eop count must be set slightly greater then 0x2ee0. count (bits [13:0]) the count field contains the current value of the sof/eop down counter. at power-up and reset, this value is set to 0x2ee0 and for expected 1-ms sof/eop in tervals, this sof/eop count should be increased slightly. reserved all reserved bits must be written as ?0?. otg control registers [9] there is one register dedicated fo r otg operation. this register is covered in this section and summarized in table 28 . otg control register [0xc098] [r/w] figure 40. otg control register register description the otg control register allows control and monitoring over the otg port on port1a. vbus pull-up enable (bit 13) the vbus pull-up enable bit enables or disables a 500 ohm pull-up resistor onto otg vbus. 1: 500 ohm pull-up resistor enabled 0: 500 ohm pull-up resistor disabled receive disable (bit 12) the receive disable bit enables or powers down (disables) the otg receiver section. 1: otg receiver powered down and disabled 0: otg receiver enabled charge pump enable (bit 11) the charge pump enable bit enables or disables the otg vbus charge pump. 1: otg vbus charge pump enabled 0: otg vbus charge pump disabled vbus discharge enable (bit 10) the vbus discharge enable bit enables or disables a 2k-ohm discharge pull-down resistor onto otg vbus. 1: 2k-ohm pull-down resistor enabled 0: 2k-ohm pull-down resistor disabled d+ pull-up enable (bit 9) the d+ pull-up enable bit enables or disables a pull-up resistor on the otg d+ data line. 1: otg d+ dataline pull-up resistor enabled 0: otg d+ dataline pull-up resistor disabled d? pull-up enable (bit 8) the d? pull-up enable bit enables or disables a pull-up resistor on the otg d? data line. 1: otg d? dataline pull-up resistor enabled 0: otg d? dataline pull-up resistor disabled table 28. otg registers register name address r/w otg control register c098h r/w bit # 15 14 13 12 11 10 9 8 field reserved vbus pull-up enable receive disable charge pump enable vbus discharge enable d+ pull-up enable d? pull-up enable read/write - - r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field d+ pull-down enable d? pull-down enable reserved otg data status id status vbus valid flag read/write r/w r/w - - - r r r default 0 0 0 0 0 x x x note 9. errata: the vbus interrupt in the host/device status registers [0xc090 and 0xc0b0] and otg control register [0xc098] triggers multiple times whenever vbus is turned on. it should only trigger once when vbus rises above 4. 4 v and once when vbus falls from above 4.4 v to 0 v. for mor e information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 43 of 93 d+ pull-down enable (bit 7) the d+ pull-down enable bit enables or disables a pull-down resistor on the otg d+ data line. 1: otg d+ dataline pull-down resistor enabled 0: otg d+ dataline pull-down resistor disabled d? pull-down enable (bit 6) the d? pull-down enable bit enables or disables a pull-down resistor on the otg d? data line. 1: otg d? dataline pull-down resistor enabled 0: otg d? dataline pull-down resistor disabled otg data status (bit 2) the otg data status bit is a read only bit and indicates the ttl logic state of the otg vbus pin. 1: otg vbus is greater than 2.4 v 0: otg vbus is less than 0.8 v id status (bit 1) the id status bit is a read only bit that indicates the state of the otg id pin on port a. 1: otg id pin is not connected directly to ground (>10k ohm) 0: otg id pin is connected directly ground (< 10 ohm) vbus valid flag (bit 0) the vbus valid flag bit indicates whether otg vbus is greater than 4.4 v. after turning on vbus, firmware should wait at least 10 s before this reading this bit. 1: otg vbus is greater then 4.4 v 0: otg vbus is less then 4.4 v reserved all reserved bits must be written as ?0?. gpio registers there are seven registers dedicated for gpio operations. these seven registers are co vered in this section and summarized in ta b l e 2 9 . gpio control register [0xc006] [r/w] figure 41. gpio control register table 29. gpio registers register name address r/w gpio control register 0xc006 r/w gpio0 output data register 0xc01e r/w gpio0 input data register 0xc020 r gpio0 direction register 0xc022 r/w gpio1 output data register 0xc024 r/w gpio1 input data register 0xc026 r gpio1 direction register 0xc028 r/w bit # 15 14 13 12 11 10 9 8 field write protect enable reserved reserved sas enable mode select read/write r/w - r - r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field hss enable reserved spi enable reserved interrupt 0 polarity select interrupt 0 enable read/write r/w - r/w - - - r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 44 of 93 register description the gpio control register configures the gpio pins for various interface options. it also cont rols the polarity of the gpio interrupt on irq0 (gpio24). write protect enable (bit 15) the write protect enable bit enables or disables the gpio write protect. when write protect is enabled, the gpio mode select [15:8] bits are read-only until a chip reset. 1: enable write protect 0: disable write protect sas enable (bit 11) the sas enable bit, when in spi mode, reroutes the spi port spi_nssi pin to gpio[15] rather then gpio[9]. 1: reroute spi_nss to gpio[15] 0: leave spi_nss on gpio[9] mode select (bits [10:8]) the mode select field selects how gpio[15:0] and gpio[24:19] are used as defined in table 30 . hss enable (bit 7) the hss enable bit routes hss to gpio[15:12]. 1: hss is routed to gpio 0: hss is not routed to gpios. gpio[15:12] are free for other purposes. spi enable (bit 5) the spi enable bit routes spi to gpio[11:8]. if the sas enable bit is set, it overrides and rout es the spi_nssi pin to gpio15. 1: spi is routed to gpio[11:8] 0: spi is not routed to gpio[11:8] . gpio[11:8] are free for other purposes. interrupt 0 polarity select (bit 1) the interrupt 0 polarity select bi t selects the polarity for irq0. 1: sets irq0 to rising edge 0: sets irq0 to falling edge interrupt 0 enable (bit 0) the interrupt 0 enable bit enables or disables irq0. the gpio bit on the interrupt enable register must also be set in order for this for this interrupt to be enabled. 1: enable irq0 0: disable irq0 reserved all reserved bits must be written as ?0?. gpio 0 output data register [0xc01e] [r/w] figure 42. gpio 0 output data register table 30. mode select definition mode select [10:8] gpio configuration 111 reserved 110 scan ? (hw) scan diagnostic. for produc- tion test only. not for normal operation 101 hpi ? host port interface 100 reserved 011 reserved 010 reserved 001 reserved 000 gpio ? general purpose input output table 30. mode select definition (continued) bit # 15 14 13 12 11 10 9 8 field gpio15 gpio14 gpio13 gpio12 gpio11 gpio10 gpio9 gpio8 read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field gpio7 gpio6 gpio5 gpio4 gpio3 gpio2 gpio1 gpio0 read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 45 of 93 register description the gpio 0 output data register controls th e output data of the gp io pins. the gpio 0 output data register controls gpio15 to gpio0 while the gpio 1 output data register controls gpio31 to gpio19. when read, this register reads back the last data writte n, not the data on pins configured as inputs (see input data register). writing a 1 to any bit will output a high voltage on the corresponding gpio pin. reserved all reserved bits must be written as ?0?. gpio 1 output data r egister [0xc024] [r/w] figure 43. gpio n output data register register description the gpio 1 output data register controls th e output data of the gp io pins. the gpio 0 output data register controls gpio15 to gpio0 while the gpio 1 output data register controls gpio31 to gpio19. when read, this register reads back the last data writte n, not the data on pins configured as inputs (see input data register). writing a 1 to any bit will output a high voltage on the corresponding gpio pin. reserved all reserved bits must be written as ?0?. gpio 0 input data register [0xc020] [r] figure 44. gpio 0 input data register bit # 15 14 13 12 11 10 9 8 field gpio31 gpio30 gpio29 reserved gpio24 read/write r/w r/w r/w - - - - r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field gpio23 gpio22 gpio21 gp io20 gpio19 reserved read/write r/w r/w r/w r/w r/w - - - default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field gpio15 gpio14 gpio13 gpio12 gpio11 gpio10 gpio9 gpio8 read/write r r r r r r r r default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field gpio7 gpio6 gpio5 gpio4 gpio3 gpio2 gpio1 gpio0 read/write r r r r r r r r default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 46 of 93 register description the gpio 0 input data register reads the input data of the gpio pins. the gpio 0 input data register reads from gpio15 to gpio0 while the gpio 1 input data register reads from gpio31 to gpio19. every bit represents the vo ltage of that gpio pin. gpio 1 input data register [0xc026] [r] figure 45. gpio 1 input data register register description the gpio 1 input data register reads the input data of the gpio pins. the gpio 0 input data register reads from gpio15 to gpio0 while the gpio 1 input data register reads from gpio31 to gpio19. every bit represents the vo ltage of that gpio pin. gpio 0 direction register [0xc022] [r/w] figure 46. gpio 0 direction register bit # 15 14 13 12 11 10 9 8 field gpio31 gpio30 gpio29 reserved gpio24 read/write r r r - - - - r default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field gpio23 gpio22 gpio21 gp io20 gpio19 reserved read/write r r r r r - - - default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field gpio15 gpio14 gpio13 gpio12 gpio11 gpio10 gpio9 gpio8 read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field gpio7 gpio6 gpio5 gpio4 gpio3 gpio2 gpio1 gpio0 read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 47 of 93 register description the gpio 0 direction register controls the direction of the gpio data pins (input/outp ut). the gpio 0 direction register contro ls gpio15 to gpio0 while the gpio 1 directi on register controls gpio31 to gpio19. when any bit of this register is set to ?1?, the corresponding gpio data pin becomes an output. when any bit of this register i s set to ?0?, the corresponding gpio data pin becomes an input. reserved all reserved bits must be written as ?0?. gpio 1 direction register [0xc028] [r/w] figure 47. gpio 1 direction register register description the gpio 1 direction register controls the direction of the gpio data pins (input/outp ut). the gpio 0 direction register contro ls gpio15 to gpio0 while the gpio 1 directi on register controls gpio31 to gpio19. when any bit of this register is set to ?1?, the corresponding gpio data pin becomes an output. when any bit of this register i s set to ?0?, the corresponding gpio data pin becomes an input. reserved all reserved bits must be written as ?0?. hss registers there are eight registers dedicat ed to hss operation. each of these registers are covered in this section and summarized in ta b l e 3 1 . bit # 15 14 13 12 11 10 9 8 field gpio31 gpio30 gpio29 reserved gpio24 read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field gpio23 gpio22 gpio21 gp io20 gpio19 reserved read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 table 31. hss registers register name address r/w hss control register 0xc070 r/w hss baud rate register 0xc072 r/w hss transmit gap register 0xc074 r/w hss data register 0xc076 r/w hss receive address register 0xc078 r/w hss receive length register 0xc07a r/w hss transmit address register 0xc07c r/w hss transmit length register 0xc07e r/w
cy7c67200 document number: 38-08014 rev. *j page 48 of 93 hss control register [0xc070] [r/w] figure 48. hss control register register description the hss control register provides high-level status and control over the hss port. hss enable (bit 15) the hss enable bit enables or disables hss operation. 1: enables hss operation 0: disables hss operation rts polarity select (bit 14) the rts polarity select bit selects the polarity of rts. 1: rts is true when low 0: rts is true when high cts polarity select (bit 13) the cts polarity select bit selects the polarity of cts. 1: cts is true when low 0: cts is true when high xoff (bit 12) the xoff bit is a read-only bit that indicates if an xoff has been received. this bit is automat ically cleared when an xon is received. 1: xoff received 0: xon received xoff enable (bit 11) the xoff enable bit enables or disables xon/xoff software handshaking. 1: enable xon/xoff software handshaking 0: disable xon/xoff software handshaking cts enable (bit 10) the cts enable bit enables or disables cts/rts hardware handshaking. 1: enable cts/rts hardware handshaking 0: disable cts/rts hardware handshaking receive interrupt enable (bit 9) the receive interrupt enable bit enables or disables the receive ready and receive packet ready interrupts. 1: enable the receive ready and receive packet ready inter- rupts 0: disable the receive ready and receive packet ready inter- rupts done interrupt enable (bit 8) the done interrupt enable bit enables or disables the transmit done and receive done interrupts. 1: enable the transmit done and receive done interrupts 0: disable the transmit done and receive done interrupts transmit done interrupt flag (bit 7) the transmit done interrupt flag bit indicates the status of the transmit done interrupt. it will set when a block transmit is finished. to clear the interrupt, a ?1? must be written to this bit. 1: interrupt triggered 0: interrupt did not trigger receive done interrupt flag (bit 6) the receive done interrupt flag bit indicates the status of the receive done interrupt. it will set when a block transmit is finished. to clear the interrupt, a ?1? must be written to this bit. 1: interrupt triggered 0: interrupt did not trigger one stop bit (bit 5) the one stop bit bit selects between one and two stop bits for transmit byte mode. in receive mode, the number of stop bits may vary and does not need to be fixed. 1: one stop bit 0: two stop bits bit # 15 14 13 12 11 10 9 8 field hss enable rts polarity select cts polarity select xoff xoff enable cts enable receive interrupt enable done interrupt enable read/write r/w r/w r/w r r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field transmit done interrupt enable receive done interrupt enable one stop bit transmit ready packet mode select receive overflow flag receive packet ready flag receive ready flag read/write r/w r/w r/w r r/w r/w r r default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 49 of 93 transmit ready (bit 4) the transmit ready bit is a read only bit that indicates if the hss transmit fifo is ready for the cpu to load new data for trans- mission. 1: hss transmit fifo ready for loading 0: hss transmit fifo not ready for loading packet mode select (bit 3) the packet mode select bit se lects between receive packet ready and receive ready as the interrupt source for the rxintr interrupt. 1: selects receive packet ready as the source 0: selects receive ready as the source receive overflow flag (bit 2) the receive overflow flag bit indicates if the receive fifo overflowed when set. this flag can be cleared by writing a ?1? to this bit. 1: overflow occurred 0: overflow did not occur receive packet ready flag (bit 1) the receive packet ready flag bit is a read only bit that indicates if the hss receive fifo is full with eight bytes. 1: hss receive fifo is full 0: hss receive fifo is not full receive ready flag (bit 0) the receive ready flag is a read only bit that indicates if the hss receive fifo is empty. 1: hss receive fifo is not empty (one or more bytes is reading for reading) 0: hss receive fifo is empty hss baud rate register [0xc072] [r/w] figure 49. hss baud rate register bit # 15 14 13 12 11 10 9 8 field reserved baud... read/write - - - r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...baud read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 1 0 1 1 1
cy7c67200 document number: 38-08014 rev. *j page 50 of 93 register description the hss baud rate register sets the hss baud rate. at reset, the default value is 0x0017 which sets the baud rate to 2.0 mhz. baud (bits [12:0]) the baud field is the baud rate divisor minus one, in units of 1/48 mhz. therefore the baud rate = 48 mhz/(baud + 1). this puts a constraint on the baud value as follows: (24 ? 1) < baud > (5000 ? 1) reserved all reserved bits must bit written as ?0?. hss transmit gap register [0xc074] [r/w] figure 50. hss transmit gap register register description the hss transmit gap register is only valid in block transmit mode. it allows for a pr ogrammable number of stop bits to be inse rted thus overwriting the one stop bit in the hss control register. th e default reset value of this register is 0x0009, equivalent t o two stop bits. transmit gap select (bits [7:0]) the transmit gap select field sets the inactive time between tran smitted bytes. the inactive time = (transmit gap select ? 7) * bit time. therefore an transmit gap select value of 8 is equal to having one stop bit. reserved all reserved bits must be written as ?0?. hss data register [0xc076] [r/w] figure 51. hss data register bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field transmit gap select read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 1 0 0 1 bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field data read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 51 of 93 register description the hss data register contains data received on the hss port (not for block receive mode) when read. this receive data is valid when the receive ready bit of the hss control register is set to ?1?. writing to this register initiates a single byte transfer of data. the transmit ready flag in the hss control register must read ?1? befo re writing to this register (t his avoids disrupting the previ ous/current transmission). data (bits [7:0]) the data field contains the data received or to be transmitted on the hss port. reserved all reserved bits must be written as ?0?. hss receive address register [0xc078] [r/w] figure 52. hss receive address register register description the hss receive address register is used as the base poi nter address for the next hss block receive transfer. address (bits [15:0]) the address field sets the base pointer address for the next hss block receive transfer. hss receive counter register [0xc07a] [r/w] figure 53. hss receive counter register bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved counter... read/write - - - - - - r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...counter read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 52 of 93 register description the hss receive counter register designates the block byte length for the next hss receive transfer. this register must be load ed with the word count minus one to start the block receive transfer. as each byte is received this register value is decremented. when read, this register indicates the remaining length of the transfer. counter (bits [9:0]) the counter field value is equal to the word count minus one givi ng a maximum value of 0x03ff (1023) or 2048 bytes. when the transfer is complete this register returns 0x03ff until reloaded. reserved all reserved bits must be written as ?0?. hss transmit address register [0xc07c] [r/w] figure 54. hss transmit address register register description the hss transmit address register is used as the base pointer address for the next hss block transmit transfer. address (bits [15:0]) the address field sets the base pointer address for the next hss block transmit transfer. hss transmit counter register [0xc07e] [r/w] figure 55. hss transmit counter register bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved counter... read/write - - - - - - r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...counter read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 53 of 93 register description the hss transmit counter regist er designates the block byte length for the next hss transmit transfer. this register must be loaded with the word count minus o ne to start the block transmit transfer. as each byte is transmitted this register value is decre- mented. when read, this register indicates the remaining length of the transfer. counter (bits [9:0]) the counter field value is equal to the word count minus one giving a maximum value of 0x03ff (1023) or 2048 bytes. when the transfer is complete this register returns 0x03ff until reloaded. reserved all reserved bits must be written as ?0?. hpi registers there are five registers dedicated to hpi operation. in addition, there is an hpi status port which can be address over hpi. each of these registers is covered in this section and are summarized in table 32 . hpi breakpoint register [0x0140] [r] figure 56. hpi breakpoint register register description the hpi breakpoint register is a special on-chip memory locati on, which the external processor can access using normal hpi memo ry read/write cycles. this register is read-only by the cpu but is read/write by the hpi port. the c ontents of this register have the same effect as the breakpoint register [0xc014]. this special break point register is used by software debuggers which interface thro ugh the hpi port instead of the serial port. when the program counter matches the breakpoint address, the int127 interrupt triggers. to clear this interrupt, a zero value m ust be written to this register. address (bits [15:0]) the address field is a 16-bit field containing the breakpoint address. interrupt routing register [0x0142] [r] figure 57. interrupt routing register table 32. hpi registers register name address r/w hpi breakpoint register 0x0140 r interrupt routing register 0x0142 r sie1msg register 0x0144 w sie2msg register 0x0148 w hpi mailbox register 0xc0c6 r/w bit # 15 14 13 12 11 10 9 8 field address... read/write r r r r r r r r default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r r r r r r r r default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field vbus to hpi enable id to hpi enable sof/eop2 to hpi enable sof/eop2 to cpu enable sof/eop1 to hpi enable sof/eop1 to cpu enable reset2 to hpi enable hpi swap 1 enable read/write r r r r r r r r default 0 00101 0 0 bit # 7 6 5 4 3 2 1 0 field resume2 to hpi enable resume1 to hpi enable reserved done2 to hpi enable done1 to hpi enable reset1 to hpi enable hpi swap 0 enable read/write - - - - - - - - default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 54 of 93 register description the interrupt routing register allo ws the hpi port to take over some or all of the sie interrupts that usually go to the on-chip cpu. this register is read-only by the cpu but is read/write by the hpi port. by setting the appropria te bit to ?1?, the sie interrupt is routed to the hpi port to become the hpi_intr signal and also readable in the hpi status register. the bits in this register select where the interrupts are routed. the individual interrupt enable is handled in the sie interrupt enable register. vbus to hpi enable (bit 15) the vbus to hpi enable bit rout es the otg vbus interrupt to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port id to hpi enable (bit 14) the id to hpi enable bit routes the otg id interrupt to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port sof/eop2 to hpi enable (bit 13) the sof/eop2 to hpi enable bit routes the sof/ eop2 interrupt to the hpi port. 1: route signal to hpi port 0: do not route signal to hpi port sof/eop2 to cpu enable (bit 12) the sof/eop2 to cpu enable bit routes the sof/eop2 interrupt to the on-chip cpu. si nce the sof/eop2 interrupt can be routed to both the on-chip cpu and the hpi port the firmware must ensure only one of the two (cpu, hpi) resets the interrupt. 1: route signal to cpu 0: do not route signal to cpu sof/eop1 to hpi enable (bit 11) the sof/eop1 to hpi enable bit routes the sof/ eop1 interrupt to the hpi port. 1: route signal to hpi port 0: do not route signal to hpi port sof/eop1 to cpu enable (bit 10) the sof/eop1 to cpu enable bit routes the sof/eop1 interrupt to the on-chip cpu. si nce the sof/eop1 interrupt can be routed to both the on-chip cpu and the hpi port the firmware must ensure only one of the two (cpu, hpi) resets the interrupt. 1: route signal to cpu 0: do not route signal to cpu reset2 to hpi enable (bit 9) the reset2 to hpi enable bit routes the usb reset interrupt that occurs on device 2 to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port hpi swap 1 enable (bit 8) both hpi swap bits (bits 8 and 0) must be set to identical values. when set to ?00?, the most significant data byte goes to hpi_d[15:8] and the least significant byte goes to hpi_d[7:0]. this is the default setting. by se tting to ?11?, the most significant data byte goes to hpi_d[7:0] and the least significant byte goes to hpi_d[15:8]. resume2 to hpi enable (bit 7) the resume2 to hpi enable bit routes the usb resume interrupt that occurs on host 2 to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port resume1 to hpi enable (bit 6) the resume1 to hpi enable bit routes the usb resume interrupt that occurs on host 1 to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port done2 to hpi enable (bit 3) the done2 to hpi enable bit routes the done interrupt for host/device 2 to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port done1 to hpi enable (bit 2) the done1 to hpi enable bit routes the done interrupt for host/device 1 to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port reset1 to hpi enable (bit 1) the reset1 to hpi enable bit routes the usb reset interrupt that occurs on device 1 to the hpi port instead of the on-chip cpu. 1: route signal to hpi port 0: do not route signal to hpi port
cy7c67200 document number: 38-08014 rev. *j page 55 of 93 hpi swap 0 enable (bit 0) both hpi swap bits (bits 8 and 0) must be set to identical values . when set to ?00?, the most significant data byte goes to hpi _d[15:8] and the least significant byte goes to hpi_ d[7:0]. this is the default setting. by setting to ?11?, the most significant data b yte goes to hpi_d[7:0] and the least signific ant byte goes to hpi_d[15:8]. siexmsg register [w] [10] ? sie1msg register 0x0144 ? sie2msg register 0x0148 figure 58. siexmsg register register description the siexmsg register allows an interrupt to be generated on the hpi port. any write to this register causes the siexmsg flag in the hpi status port to go high and also causes an interrupt on the hpi_intr pin. the siexmsg flag is automatically cleared when the hpi port reads from this register. data (bits [15:0]) the data field[15:0] simply must have any value written to it to cause siexmsg flag in the hpi status port to go high. hpi mailbox register [0xc0c6] [r/w] figure 59. hpi mailbox register register description the hpi mailbox register provides a common mailbox between the cy7c67200 and the external host processor. if enabled, the hpi mailbox rx full interrupt triggers when the ex ternal host processor writes to this register. when the cy7c6 7200 reads this register the hpi mailbox rx full interrupt automatically gets cleared. if enabled, the hpi mailbox tx empty interrupt triggers when the external host processor reads from this register. the hpi mail box tx empty interrupt is automatically cleared when the cy7c67200 writes to this register. in addition, when the cy7c67200 writes to this register, the hpi_ intr signal on the hpi port asserts signaling the external pro cessor that there is data in the mailbox to read. the hpi_intr signal deasserts when the external host processor reads from this regis ter. message (bits [15:0]) the message field contains the message that the host processor wrote to the hpi mailbox register. bit # 15 14 13 12 11 10 9 8 field data... read/write w w w w w w w w default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field ...data read/write w w w w w w w w default x x x x x x x x bit # 15 14 13 12 11 10 9 8 field message... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...message read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 note 10. errata: the sie1msg and sie2msg registers [0x0144 and 0x0148] are not initialized at power up. for more information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 56 of 93 hpi status port [] [hpi: r] figure 60. hpi status port register description the hpi status port provides the external host processor with the mailbox status bits plus several sie status bits. this register is not accessible from the on-chi p cpu. the additional sie status bits are provided to aid external device driver firmware devel- opment, and are not recommended fo r applications that do not have an intimate relationship with the on-chip bios. reading from the hpi status port does not result in a cpu hpi interface memory acce ss cycle. the external host may continu- ously poll this register without d egrading the cpu or dma perfor- mance. vbus flag (bit 15) the vbus flag bit is a read-only bit that indicates whether otg vbus is greater than 4.4 v. af ter turning on vbus, firmware should wait at least 10 s before this reading this bit. 1: otg vbus is greater then 4.4 v 0: otg vbus is less then 4.4 v id flag (bit 14) the id flag bit is a read-only bit that indicates the state of the otg id pin. sof/eop2 flag (bit 12) the sof/eop2 flag bit is a read-only bit that indicates if a sof/eop interrupt occurs on either host/device 2. 1: interrupt triggered 0: interrupt did not trigger sof/eop1 flag (bit 10) the sof/eop1 flag bit is a read-only bit that indicates if a sof/eop interrupt occurs on either host/device 1. 1: interrupt triggered 0: interrupt did not trigger reset2 flag (bit 9) the reset2 flag bit is a read-only bit that indicates if a usb reset interrupt occurs on either host/device 2. 1: interrupt triggered 0: interrupt did not trigger mailbox in flag (bit 8) the mailbox in flag bit is a read-only bit that indicates if a message is ready in the incoming mailbox. this interrupt clears when on-chip cpu reads from the hpi mailbox register. 1: interrupt triggered 0: interrupt did not trigger resume2 flag (bit 7) the resume2 flag bit is a read-only bit that indicates if a usb resume interrupt occurs on either host/device 2. 1: interrupt triggered 0: interrupt did not trigger resume1 flag (bit 6) the resume1 flag bit is a read-only bit that indicates if a usb resume interrupt occurs on either host/device 1. 1: interrupt triggered 0: interrupt did not trigger sie2msg (bit 5) the sie2msg flag bit is a read- only bit that indicates if the cy7c67200 cpu has written to the sie2msg register. this bit is cleared on an hpi read. 1: the sie2msg register has been written by the cy7c67200 cpu 0: the sie2msg register has not been written by the cy7c67200 cpu sie1msg (bit 4) the sie1msg flag bit is a read- only bit that indicates if the cy7c67200 cpu has written to the sie1msg register. this bit is cleared on an hpi read. 1: the sie1msg register has been written by the cy7c67200 cpu 0: the sie1msg register has not been written by the cy7c67200 cpu bit # 15 14 13 12 11 10 9 8 field vbus flag id flag reserved sof/eop2 flag reserved sof/eop1 flag reset2 flag mailbox in flag read/write r r - r - r r r default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field resume2 flag resume1 flag sie2msg sie1msg done2 flag done1 flag reset1 flag mailbox out flag read/write r r r r r r r r default x x x x x x x x
cy7c67200 document number: 38-08014 rev. *j page 57 of 93 done2 flag (bit 3) in host mode the done2 flag bit is a read-only bit that indicates if a host packet done interrupt occurs on host 2. in device mode this read only bit indicates if any of the endpoint interrupts occurs on device 2. firmware needs to determine which endpoint interrupt occurred. 1: interrupt triggered 0: interrupt did not trigger done1 flag (bit 2) in host mode the done 1 flag bit is a read-only bit that indicates if a host packet done interrupt occurs on host 1. in device mode this read-only bit indicates if any of the endpoint interrupts occurs on device 1. firmware needs to determine which endpoint interrupt occurred. 1: interrupt triggered 0: interrupt did not trigger reset1 flag (bit 1) the reset1 flag bit is a read-only bit that indicates if a usb reset interrupt occurs on either host/device 1. 1: interrupt triggered 0: interrupt did not trigger mailbox out flag (bit 0) the mailbox out flag bit is a read-only bit that indicates if a message is ready in the outgoing mailbox. this interrupt clears when the external host reads fr om the hpi mailbox register. 1: interrupt triggered 0: interrupt did not trigger spi registers there are 12 registers dedicated to spi operation. each register is covered in this section and summarized in ta b l e 3 3 . spi configuration register [0xc0c8] [r/w] figure 61. spi configuration register table 33. spi registers register name address r/w spi configuration register 0xc0c8 r/w spi control register 0xc0ca r/w spi interrupt enable register 0xc0cc r/w spi status register 0xc0ce r spi interrupt clear register 0xc0d0 w spi crc control register 0xc0d2 r/w spi crc value 0xc0d4 r/w spi data register 0xc0d6 r/w spi transmit address register 0xc0d8 r/w spi transmit count register 0xc0da r/w spi receive address register 0xc0dc r/w spi receive count register 0xc0de r/w bit # 15 14 13 12 11 10 9 8 field 3wire enable phase select sck polarity select scale select reserved read/write r/w r/w r/w r/w r/w r/w r/w - default 1 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field master active enable master enable ss enable ss delay select read/write r r/w r/w r/w r/w r/w r/w r/w default 0 0 0 1 1 1 1 1
cy7c67200 document number: 38-08014 rev. *j page 58 of 93 register description the spi configuration register controls the spi port. fields apply to both ma ster and slave mode unless otherwise noted. 3wire enable (bit 15) the 3wire enable bit indicates if the miso and mosi data lines are tied together allowing only half duplex operation. 1: miso and mosi data lines are tied together 0: normal miso and mosi full duplex operation (not tied together) phase select (bit 14) the phase select bit selects advanced or delayed sck phase. this field only applies to master mode. 1: advanced sck phase 0: delayed sck phase sck polarity select (bit 13) this sck polarity select bit selects the polarity of sck. 1: positive sck polarity 0: negative sck polarity scale select (bits [12:9]) the scale select field provides control over the sck frequency, based on 48 mhz. see ta b l e 3 4 for a definition of this field. this field only applies to master mode. master active enable (bit 7) the master active enable bit is a read-only bit that indicates if the master state machine is active or idle. this field only applies to master mode. 1: master state machine is active 0: master state machine is idle master enable (bit 6) the master enable bit sets the spi interface to master or slave. this bit is only writable when the master active enable bit reads ?0?, otherwise value will not change. 1: master spi interface 0: slave spi interface ss enable (bit 5) the ss enable bit enables or disables the master ss output. 1: enable master ss output 0: disable master ss output (three-state master ss output, for single ss line in slave mode) ss delay select (bits [4:0]) when the ss delay select field is set to ?00000? this indicates manual mode. in manual mode ss is controlled by the ss manual bit of the spi control register. when the ss delay select field is set between ?00001? to ?11111?, this value indicates the count in half bit times of auto tr ansfer delay for: ss low to sck active, sck inactive to ss high, ss high time. this field only applies to master mode. table 34. scale select field definition for sck frequency scale select [12:9] sck frequency 0000 12 mhz 0001 8 mhz 0010 6 mhz 0011 4 mhz 0100 3 mhz 0101 2 mhz 0110 1.5 mhz 0111 1 mhz 1000 750 khz 1001 500 khz 1010 375 khz 1011 250 khz 1100 375 khz 1101 250 khz 1110 375 khz 1111 250 khz
cy7c67200 document number: 38-08014 rev. *j page 59 of 93 spi control register [0xc0ca] [r/w] figure 62. spi control register register description the spi control register controls the spi port. fields apply to both master and slave mode unless otherwise noted. sck strobe (bit 15) the sck strobe bit starts the sck strobe at the selected frequency and polarity (set in the spi configuration register), but not phase. this bit feature can only be enabled when in master mode and must be during a period of inactivity. this bit is self-clearing. 1: sck strobe enable 0: no function fifo init (bit 14) the fifo init bit initializes the fifo and clear the fifo error status bit. this bit is self-clearing. 1: fifo init enable 0: no function byte mode (bit 13) the byte mode bit selects between pio (byte mode) and dma (block mode) operation. 1: set pio (byte mode) operation 0: set dma (block mode) operation full duplex (bit 12) the full duplex bit selects between full-duplex and half-duplex operation. 1: enable full duplex. full duplex is not allowed and will not set if the 3wire enable bit of the spi configuration register is set to ?1? 0: enable half-duplex operation ss manual (bit 11) the ss manual bit activates or deactivates ss if the ss delay select field of the spi control register is all zeros and is configured as master interface. this field only applies to master mode. 1: activate ss, master drives ss line asserted low 0: deactivate ss, master dr ives ss line deasserted high read enable (bit 10) the read enable bit initiates a read phase for a master mode transfer or set the slave to receive (in slave mode). 1: initiates a read phase for a master transfer or sets a slave to receive. in master mode this bit is sticky and remains set until the read transfer begins. 0: initiates the write phase for slave operation transmit ready (bit 9) the transmit ready bit is a read-only bit that indicates if the transmit port is ready to empty and ready to be written. 1: ready for data to be written to the port. the transmit fifo is not full. 0: not ready for data to be written to the port receive data ready (bit 8) the receive data ready bit is a read-only bit that indicates if the receive port has data ready. 1: receive port has data ready to read 0: receive port does not have data ready transmit empty (bit 7) the transmit empty bit is a read-only bit that indicates if the transmit fifo is empty. 1: transmit fifo is empty 0: transmit fifo is not empty receive full (bit 6) the receive full bit is a read-only bit that indicates if the receive fifo is full. 1: receive fifo is full 0: receive fifo is not full transmit bit length (bits [5:3]) the transmit bit length field controls whether a full byte or partial byte is to be transmitted. if transmit bit length is ?000?, a full byte is transmitted. if transm it bit length is ?001? to ?111?, the value indicates the number of bits that will be transmitted. bit # 15 14 13 12 11 10 9 8 field sck strobe fifo init byte mode full duplex ss manual read enable transmit ready receive data ready read/write w w r/w r/w r/w r/w r r default 0 0 0 0 0 0 0 1 bit # 7 6 5 4 3 2 1 0 field transmit empty receive full transmit bit length receive bit length read/write r r r/w r/w r/w r/w r/w r/w default 1 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 60 of 93 receive bit length (bits [2:0]) the receive bit length field controls whether a full byte or partial byte will be received. if receive bit length is ?000? then a full byte will be received. if receive bit length is ?001? to ?111?, then the value indicates the number of bits that will be received. spi interrupt enable re gister [0xc0cc] [r/w] figure 63. spi interrupt enable register register description the spi interrupt enable register controls the spi port. receive interrupt enable (bit 2) the receive interrupt enable bit enables or disables the byte mode receive interrupt (rxintval). 1: enable byte mode receive interrupt 0: disable byte mode receive interrupt transmit interrupt enable (bit 1) the transmit interrupt enable bit enables or disables the byte mode transmit inte rrupt (txintval). 1: enables byte mode transmit interrupt 0: disables byte mode transmit interrupt transfer interrupt enable (bit 0) the transfer interrupt enable bit enables or disables the block mode interrupt (xfrblkintval). 1: enables block mode interrupt 0: disables block mode interrupt reserved all reserved bits must be written as ?0?. spi status register [0xc0ce] [r] figure 64. spi status register bit # 15 14 13 12 11 10 9 8 field reserved... read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved receive interrupt enable transmit interrupt enable transfer interrupt enable read/write - - - - - r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field fifo error flag reserved receive interrupt flag transmit interrupt flag transfer interrupt flag read/write r - - - - r r r default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 61 of 93 register description the spi status register is a read only register that provides status for the spi port. fifo error flag (bit 7) the fifo error flag bit is a read only bit that indicates if a fifo error occurred. when this bit is set to ?1? and the transmit empty bit of the spi control register is set to ?1?, then a tx fifo underflow has occurred. similarly, when set with the receive full bit of the spi control register, a rx fifo overflow has occured.this bit automatically clear when the spi fifo init enable bit of the spi control register is set. 1: indicates fifo error 0: indicates no fifo error receive interrupt flag (bit 2) the receive interrupt flag is a read only bit that indicates if a byte mode receive interrupt has triggered. 1: indicates a byte mode receive interrupt has triggered 0: indicates a byte mode receive interrupt has not triggered transmit interrupt flag (bit 1) the transmit interrupt flag is a r ead only bit that indicates a byte mode transmit interrupt has triggered. 1: indicates a byte mode transmit interrupt has triggered 0: indicates a byte mode transmit interrupt has not triggered transfer interrupt flag (bit 0) the transfer interrupt flag is a read only bit that indicates a block mode interrupt has triggered. 1: indicates a block mode interrupt has triggered 0: indicates a block mode interrupt has not triggered spi interrupt clear register [0xc0d0] [w] figure 65. spi interrupt clear register register description the spi interrupt clear register is a write-only register that allows the spi transmit and spi transfer interrupts to be cleared. transmit interrupt clear (bit 1) the transmit interrupt clear bit is a write-only bit that clears the byte mode transmit interrupt. this bit is self-clearing. 1: clear the byte mode transmit interrupt 0: no function transfer interrupt clear (bit 0) the transfer interrupt clear bit is a write-only bit that will clear the block mode interrupt. this bit is self clearing. 1: clear the block mode interrupt 0: no function reserved all reserved bits must be written as ?0?. spi crc control register [0xc0d2] [r/w] figure 66. spi crc control register bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field reserved transmit interrupt clear transfer interrupt clear read/write - - - - - - w w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field crc mode crc enable crc clear receive crc one in crc zero in crc reserved... read/write r/w r/w r/w r/w r/w r r - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 62 of 93 register description the spi crc control register provides control over the crc source and polynomial value. crc mode (bits [15:14) the crcmode field selects the crc polynomial as defined in ta b l e 3 5 . crc enable (bit 13) the crc enable bit enables or disables the crc operation. 1: enables crc operation 0: disables crc operation crc clear (bit 12) the crc clear bit will clear the crc with a load of all ones. this bit is self clearing and always reads ?0?. 1: clear crc with all ones 0: no function receive crc (bit 11) the receive crc bit determines whether the receive bit stream or the transmit bit stream is used for the crc data input in full duplex mode. this bit is a don?t care in half-duplex mode. 1: assigns the receive bit stream 0: assigns the transmit bit stream one in crc (bit 10) the one in crc bit is a read-only bit that indicates if the crc value is all zeros or not. 1: crc value is not all zeros 0: crc value is all zeros zero in crc (bit 9) the zero in crc bit is a read-only bit that indicates if the crc value is all ones or not. 1: crc value is not all ones 0: crc value is all ones reserved all reserved bits must be written as ?0?. spi crc value register [0xc0d4] [r/w] figure 67. spi crc value register register description the spi crc value register contains the crc value. crc (bits [15:0]) the crc field contains the spi crc. in crc mode crc7, the crc valu e will be a seven bit value [6:0]. therefore bits [15:7] are invalid in crc7 mode. table 35. crc mode definition crcmode [9:8] crc polynomial 00 mmc 16-bit: x^16 + x^12 + x^5 + 1 (ccitt standard) 01 crc7 7-bit: x^7+ x^3 + 1 10 mst 16-bit: x^16+ x^15 + x^2 + 1 11 reserved, 16-bit polynomial 1. bit # 15 14 13 12 11 10 9 8 field crc... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 1 1 1 1 1 1 1 1 bit # 7 6 5 4 3 2 1 0 field ...crc read/write r/w r/w r/w r/w r/w r/w r/w r/w default 1 1 1 1 1 1 1 1
cy7c67200 document number: 38-08014 rev. *j page 63 of 93 spi data register [0xc0d6] [r/w] figure 68. spi data register register description the spi data register contains data received on the spi port when read. reading it empties the eigh t byte receive fifo in pio b yte mode. this receive data is valid when the receive bit of the spi interrupt value is set to ?1? (rxintval triggers) or the recei ve data ready bit of the spi control register is set to ?1?. writing to this register in pio byte mode will initiate a transfer of data , the number of bits defined by transmit bit length field in the spi control register. data (bits [7:0]) the data field contains data received or to be transmitted on the spi port. reserved all reserved bits must be written as ?0?. spi transmit address register [0xc0d8] [r/w] figure 69. spi transmit address register register description the spi transmit address register is used as the base address for the spi transmit dma. address (bits [15:0]) the address field sets the base address for the spi transmit dma. bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default x x x x x x x x bit # 7 6 5 4 3 2 1 0 field data read/write r/w r/w r/w r/w r/w r/w r/w r/w default x x x x x x x x bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 64 of 93 spi transmit count register [0xc0da] [r/w] figure 70. spi transmit count register register description the spi transmit count register designates the bl ock byte length for the spi transmit dma transfer. count (bits [10:0]) the count field sets the count for the spi transmit dma transfer. reserved all reserved bits must be written as ?0?. spi receive address register [0xc0dc [r/w] figure 71. spi receive address register register description the spi receive address register is issued as the base address for the spi receive dma. address (bits [15:0]) the address field sets the base address for the spi receive dma. spi receive count register [0xc0de] [r/w] figure 72. spi receive count register bit # 15 14 13 12 11 10 9 8 field reserved count... read/write - - - - - r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...count read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field address... read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...address read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved count... read/write - - - - - r/w r/w r/w default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...count read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 65 of 93 register description the spi receive count register designates the bl ock byte length for the spi receive dma transfer. count (bits [10:0]) the count field sets the count for the spi receive dma transfer. reserved all reserved bits must be written as ?0?. uart registers there are three registers dedicated to uart operation. each of these registers is covered in this section and summarized in table 36 . uart control register [0xc0e0] [r/w] figure 73. uart control register register description the uart control register enables or disables the uart allowing gpio7 (uart_txd) and gpio6 (uart_rxd) to be freed up for general use. this register must also be written to set the baud rate, which is based on a 48-mhz clock. scale select (bit 4) the scale select bit acts as a prescaler that will divide the baud rate by eight. 1: enable prescaler 0: disable prescaler baud select (bits [3:1]) refer to table 37 for a definition of this field. uart enable (bit 0) the uart enable bit enables or disables the uart. 1: enable uart 0: disable uart. this allows gpio6 and gpio7 to be used for general use table 36. uart registers register name address r/w uart control register 0xc0e0 r/w uart status register 0xc0e2 r uart data register 0xc0e4 r/w bit # 15 14 13 12 11 10 9 8 field reserved... read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved scale select baud select uart enable read/write - - - r/w r/w r/w r/w r/w default 0 0 0 0 0 1 1 1 table 37. uart baud select definition baud select [3:1] baud rate w/div8 = 0 baud rate w/div8 = 1 000 115.2k baud 14.4k baud 001 57.6k baud 7.2k baud 010 38.4k baud 4.8k baud 011 28.8k baud 3.6k baud 100 19.2k baud 2.4k baud 101 14.4k baud 1.8k baud 110 9.6k baud 1.2k baud 111 7.2k baud 0.9k baud
cy7c67200 document number: 38-08014 rev. *j page 66 of 93 reserved all reserved bits must be written as ?0?. uart status register [0xc0e2] [r] figure 74. uart status register register description the uart status register is a re ad-only register that indicates the status of the uart buffer. receive full (bit 1) the receive full bit indicates whether the receive buffer is full. it can be programmed to interrupt the cpu as interrupt #5 when the buffer is full. this can be done though the uart bit of the interrupt enable register (0xc00e). this bit will automatically be cleared when data is read from the uart data register. 1: receive buffer full 0: receive buffer empty transmit full (bit 0) the transmit full bit indicates whether the transmit buffer is full. it can be programmed to interrupt the cpu as interrupt #4 when the buffer is empty. this can be done though the uart bit of the interrupt enable register (0xc00e). this bit will automatically be set to ?1? after data is written by ez-host to the uart data register (to be transmitted). this bit will automatically be cleared to ?0? after the data is transmitted. 1: transmit buffer full (transmit busy) 0: transmit buffer is empty and ready for a new byte of data uart data register [0xc0e4] [r/w] figure 75. uart data register register description the uart data register contains data to be transmitted or receiv ed from the uart port. data written to this register will start a data transmission and also causes the uart transm it empty flag of the uart status register to set. w hen data received on the uart port is read from this register, the uart receive full flag of the uart status register will be cleared. data (bits [7:0]) the data field is where the uart data to be transmitted or received is located reserved all reserved bits must be written as ?0?. bit # 15 14 13 12 11 10 9 8 field reserved... read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field ...reserved receive full transmit full read/write - - - - - - r r default 0 0 0 0 0 0 0 0 bit # 15 14 13 12 11 10 9 8 field reserved read/write - - - - - - - - default 0 0 0 0 0 0 0 0 bit # 7 6 5 4 3 2 1 0 field data read/write r/w r/w r/w r/w r/w r/w r/w r/w default 0 0 0 0 0 0 0 0
cy7c67200 document number: 38-08014 rev. *j page 67 of 93 pin diagram the following describes the cy7c67200 48-pin fbga. figure 76. ez-otg pin diagram pin descriptions table 38. pin descriptions pin name type description h3 gpio31/sck io gpio31: general purpose io sck: i2c eeprom sck f3 gpio30/sda io gpio30: general purpose io sda: i2c eeprom sda f4 gpio29/otgid io gpio29: general purpose io otgid: input for otg id pin. when used as otgid, this pin must be tied high through an external pull-up resistor. assuming v cc = 3.0 v, a 10k to 40k resistor must be used. h4 gpio24/int/irq0 [11] io gpio24: general purpose io int: hpi int irq0: interrupt request 0. see register 0xc006. this pin is also one of two possible gpio wakeup sources. g4 gpio23/nrd io gpio23: general purpose io nrd: hpi nrd nreset a1 a2 a3 a4 a5 a6 b1 b2 b3 b4 b5 b6 h1 h2 h3 h4 h5 h6 g1 g2 g3 g4 g5 g6 f1 f2 f3 f4 f5 f6 e1 e2 e3 e4 e5 e6 d1 d2 d3 d4 d5 d6 c1 c2 c3 c4 c5 c6 gpio9/d9/ nssi reserved gnd gnd gpio3/d3 gpio1/d1 agnd vcc otgvbus gpio12/d12/ txd gpio13/d13/ rxd gpio14/d14/ rts dp1a gnd avcc boostvcc gpio10/d10/ sck dm1a gpio0/d0 dm2a vswitch boostgnd gpio8/d8/ miso gpio2/d2 gpio11/d1/ mosi dp2a cswitcha cswitchb gpio29/ otgid gpio19/a0 gpio15/d15/ cts/nssi gnd gpio20/a1 gpio22/nwr gpio21/ncs/ nreset gpio24/int/ irq0 gpio23/nrd/ nwait gpio31/scl xtalin gpio4/d4 gpio7/d7/tx vcc vcc gpio6/d6/rx gpio30/sda xtalout gpio5/d5 note 11. errata: part does not service usb isrs when gpio24 pin (also labeled as hpi_int and iordy) is low and any ide register is read. for mo re information, see the errata on page 84 .
cy7c67200 document number: 38-08014 rev. *j page 68 of 93 h5 gpio22/nwr io gpio22: general purpose io nwr: hpi nwr g5 gpio21/ncs io gpio21: general purpose io ncs: hpi ncs h6 gpio20/a1 io gpio20: general purpose io a1: hpi a1 f5 gpio19/a0 io gpio19: general purpose io a0: hpi a0 f6 gpio15/d15/cts/ nssi io gpio15: general purpose io d15: d15 for hpi cts: hss cts nssi: spi nssi e4 gpio14/d14/rts io gpio14: general purpose io d14: d14 for hpi rts: hss rts e5 gpio13/d13/rxd io gpio13: general purpose io d13: d13 for hpi rxd: hss rxd (data is received on this pin) e6 gpio12/d12/txd io gpio12: general purpose io d12: d12 for hpi txd: hss txd (data is transmitted from this pin) d4 gpio11/d11/mosi io gpio11: general purpose io d11: d11 for hpi mosi: spi mosi d5 gpio10/d10/sck io gpio10: general purpose io d10: d10 for hpi sck: spi sck c6 gpio9/d9/nssi io gpio9: general purpose io d9: d9 for hpi nssi: spi nssi c5 gpio8/d8/miso io gpio8: general purpose io d8: d8 for hpi miso: spi miso b5 gpio7/d7/tx io gpio7: general purpose io d7: d7 for hpi tx: uart tx (data is transmitted from this pin) b4 gpio6/d6/rx io gpio6: general purpose io d6: d6 for hpi rx: uart rx (data is received on this pin) c4 gpio5/d5 io gpio5: general purpose io d5: d5 for hpi b3 gpio4/d4 io gpio4: general purpose io d4: d4 for hpi a3 gpio3/d3 io gpio3: general purpose io d3: d3 for hpi c3 gpio2/d2 io gpio2: general purpose io d2: d2 for hpi a2 gpio1/d1 io gpio1: general purpose io d1: d1 for hpi b2 gpio0/d0 io gpio0: general purpose io d0: d0 for hpi f2 dm1a io usb port 1a d? e3 dp1a io usb port 1a d+ c2 dm2a io usb port 2a d? table 38. pin descriptions (continued) pin name type description
cy7c67200 document number: 38-08014 rev. *j page 69 of 93 absolute maximum ratings this section lists the absolute maximum ratings. stresses above those listed can cause perm anent damage to the device. exposure to maximum rated conditions for extended periods can affect device operation and reliability. storage temperature ................. .............. ... ?40c to +125c ambient temperature with powe r supplied.. ?40c to +85c supply voltage to ground potentia l.............. ..0.0 v to +3.6 v dc input voltage to any general purpose input pin.... 5.5 v dc voltage applied to xtalin ........... ?0.5 v to v cc + 0.5 v static discharge voltage (per mil-std-883, method 3015) > 2000 v max output current, per input output. ......................... 4 ma operating conditions t a (ambient temperature under bias) ......... ?40c to +85c supply voltage (v cc , av cc ) .........................+3.0 v to +3.6 v supply voltage (boostv cc ) [12] ......................+2.7 v to +3.6 v ground voltage................................................................. 0 v f osc (oscillator or crystal frequency).... 12 mhz 500 ppm ................................................................... parallel resonant crystal requirements (xtalin, xtalout) d3 dp2a io usb port 2a d+ g3 xtalin input crystal input or direct clock input g2 xtalout output crystal output . leave floating if direct clock source is used. a5 nreset input reset a6 reserved ? tie to gnd for normal operation . f1 boostv cc power booster power input : 2.7 v to 3.6 v e2 vswitch analog output booster switching output e1 boostgnd ground booster ground c1 otgvbus analog io usb otg vbus d1 cswitcha analog charge pump capacitor d2 cswitchb analog charge pump capacitor g1 av cc power usb power b1 agnd ground usb ground h2, d6, a4 v cc power main v cc g6, b6, a1, h1 gnd ground main ground table 38. pin descriptions (continued) pin name type description table 39. crystal requirements crystal requirements, (xtalin, xtalout) min typical max unit parallel resonant frequency 12 mhz frequency stability ?500 +500 ppm load capacitance 20 33 pf driver level 500 w start-up time 5ms mode of vibration: fundamental note 12. the on-chip voltage booster circuit boosts boostv cc to provide a nominal 3.3 v v cc supply.
cy7c67200 document number: 38-08014 rev. *j page 70 of 93 dc characteristics notes 13. all tests were conducted with charge pump off. 14. i cc and i ccb values are the same regardless of us b host or peripheral configuration. 15. there is no appreciable difference in i cc and i ccb values when only one transceiver is powered. table 40. dc characteristics [13] parameter description conditions min. typ. max. unit v cc , av cc supply voltage 3.0 3.3 3.6 v boosv cc supply voltage 2.7 ? 3.6 v v ih input high voltage 2.0 ? 5.5 v v il input low voltage ? ? 0.8 v i i input leakage current 0< v in < v cc ?10.0 ? +10.0 ? a v oh output voltage high i out = 4 ma 2.4 ? ? v v ol output low voltage i out = ?4 ma ? ? 0.4 v i oh output current high ? ? 4 ma i ol output current low ? ? 4 ma c in input pin capacitanc e except d+/d? ? ? 10 pf d+/d? ? ? 15 pf v hys hysteresis on nreset pin 250 ? ? mv i cc [14, 15] supply current 2 transceivers powered ? 80 100 ma i ccb [14, 15] supply current with booster enabled 2 transceivers powered ? 135 180 ma i sleep sleep current usb peripheral: includes 1.5k internal pull up ?210500 ? a without 1.5k internal pull up ? 5 30 ? a i sleepb sleep current with booster enabled usb peripheral: includes 1.5k internal pull up ?210500 ? a without 1.5k internal pull up ? 5 30 ? a table 41. dc characteristics: charge pump parameter description conditions min. typ. max. unit v a_vbus_out regulated otgvbus voltage 8 ma< i load < 10 ma 4.4 ? 5.25 v t a_vbus_rise v bus rise time i load = 10 ma ? 100 ms i a_vbus_out maximum load current 8 ? 10 ma c drd_vbus outvbus bypass capacitance 4.4 v< v bus < 5.25 v 1.0 ? 6.5 pf v a_vbus_lkg otgvbus leakage voltage otgvbus not driven ? ? 200 mv v drd_data_lkg dataline leakage voltage ? ? 342 mv i charge charge pump current draw i load = 8 ma ? 20 20 ma i load = 0 ma ? 0 1 ma i chargeb charge pump current draw with booster active i load = 8 ma ? 30 45 ma i load = 0 ma ? 0 5 ma i b_dschg_in b-device (srp capable) discharge current 0 v< v bus < 5.25 v ? ? 8 ma v a_vbus_valid a-device vbus valid 4.4 ? ? v
cy7c67200 document number: 38-08014 rev. *j page 71 of 93 usb transceiver usb 2.0-compatible in full- and low-speed modes. this product was tested as compliant to th e usb-if specification under the test iden tification number (tid) of 100390449 and is listed on the usb-if?s integrators list. ac timing characteristics reset timing v a_sess_valid a-device session valid 0.8 ? 2.0 v v b_sess_valid b-device session valid 0.8 ? 4.0 v v a_sess_end b-device session end 0.2 ? 0.8 v e efficiency when loaded i load = 8 ma, vcc = 3.3 v 75 ? % r pd data line pull down 14.25 ? 24.8 ? r a_bus_in a-device v bus input impedance to gnd v bus is not being driven 40 ? 100 k ? r b_srp_up b-device v bus srp pull up pull-up voltage = 3.0 v 281 ? ? ? r b_srp_dwn b-device v bus srp pull down 656 ? ? ? table 41. dc characteristics: charge pump (continued) parameter description conditions min. typ. max. unit note 16. clock is 12 mhz nominal. parameter description min. typ. max. unit t reset nreset pulse width 16 ? ? clocks [16] t ioact nreset high to nrd or nwrx active 200 ? ? s nreset nrd or nwrl or nwrh t reset t ioact reset timing
cy7c67200 document number: 38-08014 rev. *j page 72 of 93 clock timing i 2 c eeprom timing parameter description min. typ. max. unit f clk clock frequency ? 12.0 ? mhz v xinh [17] clock input high (xtalout left floating) 1.5 3.0 3.6 v t clk clock period 83.17 83.33 83.5 ns t high clock high time 36 ? 44 ns t low clock low time 36 ? 44 ns t rise clock rise time ? ? 5.0 ns t fall clock fall time ? ? 5.0 ns duty cycle 45 ? 55 % xtalin clock timing t rise t fall t high t clk t low parameter description min. typical max. unit f scl clock frequency ? ? 400 khz t low clock pulse width low 1300 ? ? ns t high clock pulse width high 600 ? ? ns t aa clock low to data out valid 900 ? ? ns t buf bus idle before new transmission 1300 ? ? ns t hd.sta start hold time 600 ? ? ns t su.sta start setup time 600 ? ? ns t hd.dat data in hold time 0 ? ? ns t su.dat data in setup time 100 ? ? ns t r input rise time ? ? 300 ns t f input fall time ? ? 300 ns t su.sto stop setup time 600 ? ? ns t dh data out hold time 0 ? ? ns note 17. v xinh is required to be 3.0 v to obtain an internal 50/50 duty cycle clock. scl t low t high t r t hd.dat t aa t dh sda in sda out 1. i2c eeprom bus timing - serial i/o t su.sta t hd.sta t f t su.dat t buf t su.sto
cy7c67200 document number: 38-08014 rev. *j page 73 of 93 figure 77. hpi (host port interface) write cycle timing parameter description min. typical max. unit t asu address setup ?1 ? ? ns t ah address hold ?1 ? ? ns t cssu chip select setup ?1 ? ? ns t csh chip select hold ?1 ? ? ns t dsu data setup 6 ? ? ns t wdh write data hold 2 ? ? ns t wp write pulse width 2 ? ? t [18] t cyc write cycle time 6 ? ? t [18] note 18. t = system clock period = 1/48 mhz. ncs nrd nwr addr [1:0] dout [15:0] t asu t wp t ah t cssu t csh t cyc t dsu t wdh
cy7c67200 document number: 38-08014 rev. *j page 74 of 93 hpi (host port interface) read cycle timing parameter description min. typ. max. unit t asu address setup ?1 ? ? ns t ah address hold ?1 ? ? ns t cssu chip select setup ?1 ? ? ns t csh chip select hold ?1 ? ? ns t acc data access time, from hpi_nrd falling ? ? 1 t [18] t rdh read data hold, relative to the earlier of hpi_nrd rising or hpi_ncs rising 0? 7 ns t rp read pulse width 2 ? ? t [18] t cyc read cycle time 6 ? ? t [18] t asu t rp t ah t cssu t csh t cyc t rdh t acc t rdh ncs nrd nwr addr [1:0] din [15:0]
cy7c67200 document number: 38-08014 rev. *j page 75 of 93 hss byte mode transmit qt_clk, cpu_a, cpuhss_cs, cpu_wr are intern al signals, included in the diagram to illustrate relationship between cpu operation s and hss port operations. bit 0 is lsb of data byte. data bits are high true: hss_txd high = data bit value ?1?. bt = bit time = 1/baud rate. hss block mode transmit block mode transmit timing is similar to byte mode, except the stop bit time is controlled by the hss_gap value. the block mode stop bit time, t gap = (hss_gap ? 9) bt, where bt is the bit time, and hss_gap is the content of the hss transmit gap register 90xc074]. the default t gap is 2 bt. bt = bit time = 1/baud rate. hss byte and block mode receive receive data arrives asynchronously relative to the internal clock. incoming data bit rate may deviate from the programmed baud rate clock by as much as 5% (with hss_rate value of 23 or higher). byte mode received bytes are buffered in a fifo. the fifo not empty condition becomes the rxrdy flag. block mode received bytes are written directly to the memory system. bit 0 is lsb of data byte. data bits are high true: hss_rxd high = data bit value ?1?. bt = bit time = 1/baud rate. cpu may start another byte transmit right after txrdy goes high start of last data bit to txrdy high: 0 min, 4 t max. (t is qt_clk period) txrdy low to start bit delay: 0 min, bt max when starting from idel. for back to back transmit, new start bit begins immediately following previous stop bit. (bt = bit period) bt bt start bit bit 0 bit 1 bit 2 bit 3 bit 4 bit 5 bit 6 bit 7 qt_clk cpu_a[2:0] cpuhss_cs cpu_wr txrdy flag hss_txd byte transmit triggered by a cpu write to the hss_txdata register stop bit start bit programmable 1 or 2 stop bits. 1 stop bit shown. hss_txd t gap bt bt +/- 5% start bit bit 0 bit 1 bit 2 bit 3 bit 4 bit 5 bit 6 bit 7 stop bit start bit hss_rxd bt +/- 5% 10 bt +/- 5% received byte added to receive fifo during the final data bit time
cy7c67200 document number: 38-08014 rev. *j page 76 of 93 hardware cts/rts handshake t ctsset-up : hss_cts setup time before hss_rts = 1.5t min. t ctshold : hss_cts hold time after start bit = 0 ns min. t = 1/48 mhz. when rts/cts hardware handshake is enabled, transmission can be held off by deasserting hss_cts at least 1.5t before hss_rts. transmission resumes w hen hss_cts returns high . hss_cts must remain high until start bit. hss_rts is deasserted in the third data bit time. an application may choose to hold hss_cts until hss_rts is deasserted, which always occurs after the start bit. tctssetup tctssetup start of transmission delayed until hss_cts goes high start of transmission not delayed by hss_cts tctshold tctshold hss_rts hss_cts hss_txd
cy7c67200 document number: 38-08014 rev. *j page 77 of 93 register summary table 42. register summary r/w address register bit 15 bit 14 bit 13 bit 12 bit 11 bit 10 bit 9 bit 8 default high bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 default low r 0x0140 hpi breakpoint address... 0000 0000 ...address 0000 0000 r 0x0142 interrupt routing vbus to hpi enable id to hpi enable sof/eop2 to hpi enable sof/eop2 to cpu enable sof/eop1 to hpi enable sof/eop1 to cpu enable reset2 to hpi enable hpi swap 1 enable 0001 0100 resume2 to hpi enable resume1 to hpi enable reserved done2 to hpi enable done1 to hpi enable reset1 to hpi enable hpi swap 0 enable 0000 0000 w 1: 0x0144 2: 0x0148 siexmsg data... xxxx xxxx ...data xxxx xxxx r/w 0x02n0 device n endpoint n control reserved xxxx xxxx in/out ignore enable sequence select stall enable iso enable nak interrupt enable direction select enable arm enable xxxx xxxx r/w 0x02n2 device n endpoint n address address... xxxx xxxx ...address xxxx xxxx r.w 0x02n4 device n endpoint n count reserved count... xxxx xxxx ...count xxxx xxxx r/w 0x02n6 device n endpoint n status reserved overflow flag underflow flag out exception flag in exception flag xxxx xxxx stall flag nak flag length exception flag set-up flag sequence status timeout flag error flag ack flag xxxx xxxx r/w 0x02n8 device n endpoint n count re- sult result... xxxx xxxx ...result xxxx xxxx r 0xc000 cpu flags reserved... 0000 0000 ...reserved global inter- rupt enable negative flag overflow flag carry flag zero flag 000x xxxx r/w 0xc002 bank address... 0000 0001 ...address reserved 000x xxxx r 0xc004 hardware revision revision... xxxx xxxx ...revision xxxx xxxx r/w 0xc006 gpio control write protect enable ud reserved sas enable mode select 0000 0000 hss enable reserved spi enable reserved interrupt 0 polarity select interrupt 0 enable 0000 0000 r/w 0xc008 cpu speed reserved... 0000 0000 .reserved cpu speed 0000 000f r/w 0xc00a power control reserved host/device 2 wake enable reserved host/device 1 wake enable otg wake enable reserved hss wake enable spi wake enable 0000 0000 hpi wake enable reserved gpi wake enable reserved boost 3v ok sleep enable halt enable 0000 0000 r/w 0xc00c watchdog timer reserved... 0000 0000 ...reserved timeout flag period select lock enable wdt enable reset strobe 0000 0000 r/w 0xc00e interrupt enable reserved otg interrupt enable spi interrupt enable reserved host/device 2 interrupt enable host/device 1 interrupt enable 0000 0000 hss interrupt enable in mailbox interrupt enable out mailbox interrupt enable reserved uart interrupt enable gpio interrupt enable timer 1 interrupt enable timer 0 interrupt enable 0001 0000 r/w 0xc098 otg control reserved vbus pull-up enable receive disable charge pump enable vbus dis- charge enable d+ pull-up enable d? pull-up enable 0000 0000 d+ pull-down enable d? pull-down enable reserved otg data sta- tus id status vbus valid flag 0000 0xxx r/w 0: 0xc010 1: 0xc012 timer n count... 1111 1111 ...count 1111 1111 r/w 0xc014 breakpoint address... 0000 0000 ...address 0000 0000 r/w 1: 0xc018 2: 0xc01a extended page n map address... ...address r/w 0xc01e gpio 0 output data gpio15 gpio14 gpio13 gpio12 gpio11 gpio10 gpio9 gpio8 0000 0000 gpio7 gpio6 gpio5 gpio4 gpio3 gpio2 gpio1 gpio0 0000 0000 r 0xc020 gpio 0 input data gpio15 gpio14 gpio13 gpio12 gpio11 gpio10 gpio9 gpio8 0000 0000 gpio7 gpio6 gpio5 gpio4 gpio3 gpio2 gpio1 gpio0 0000 0000 r/w 0xc022 gpio 0 direction gpio15 gpio14 gpio13 gpio12 gpio11 gpio10 gpio9 gpio8 0000 0000 gpio7 gpio6 gpio5 gpio4 gpio3 gpio2 gpio1 gpio0 0000 0000
cy7c67200 document number: 38-08014 rev. *j page 78 of 93 r/w 0xc024 gpio 1 output data gpio31 gpio30 gpio29 reserved gpio24 0000 0000 gpio23 gpio22 gpio21 gpio20 gpio19 reserved 0000 0000 r 0xc026 gpio 1 input data gpio31 gpio30 gpio29 reserved gpio24 0000 0000 gpio23 gpio22 gpio21 gpio20 gpio19 reserved 0000 0000 r/w 0xc028 gpio 1 direction gpio31 gpio30 gpio29 reserved gpio24 0000 0000 gpio23 gpio22 gpio21 gpio20 gpio19 reserved 0000 0000 r/w 0xc03c usb diagnostic reserved port 2a diag- nostic enable reserved port 1a diag- nostic enable reserved... 0000 0000 ...reserved pull-down enable ls pull-up enable fs pull-up enable reserved force select 0000 0000 r/w 0xc070 hss control hss enable rts polarity select cts polarity select xoff xoff enable cts enable receive inter- rupt enable done interrupt enable 0000 0000 transmit done interrupt flag receive done interrupt flag one stop bit transmit ready packet mode select receive overflow flag receive pack- et ready flag receive ready flag 0000 0000 r/w 0xc072 hss baud rate reserved hss baud... 0000 0000 ...baud 0001 0111 r/w 0xc074 hss transmit gap reserved 0000 0000 transmit gap select 0000 1001 r/w 0xc076 hss data reserved xxxx xxxx data xxxx xxxx r/w 0xc078 hss receive address address... 0000 0000 ...address 0000 0000 r/w 0xc07a hss receive counter reserved counter... 0000 0000 ...counter 0000 0000 r/w 0xc07c hss transmit address address.. 0000 0000 ...address 0000 0000 r/w 0xc07e hss transmit counter reserved counter... 0000 0000 ...counter 0000 0000 r/w 0xc080 0xc0a0 host n control reserved 0000 0000 preamble enable sequence select sync enable iso enable reserved arm enable 0000 0000 r/w 0xc082 0xc0a2 host n address address... 0000 0000 ...address 0000 0000 r/w 0xc084 0xc0a4 host n count reserved port select reserved count... 0000 0000 ...count 0000 0000 r 0xc086 0xc0a6 host n pid reserved overflow flag underflow flag reserved 0000 0000 stall flag nak flag length exception flag reserved sequence status timeout flag error flag ack flag 0000 0000 w 0xc086 0xc0a4 host n ep status reserved 0000 0000 pid select endpoint select 0000 0000 r 0xc088 0xc0a8 host n count result result... 0000 0000 ...result 0000 0000 w 0xc088 0xc0a8 host n device address reserved... 0000 0000 ...reserved address 0000 0000 r/w 0xc08a 0xc0aa usb n control reserved port a d+ status port a d? status reserved loa mode select reserved xxxx 0000 port a resistors enable reserved port a force d state suspend enable reserved port a sof/eop enable 0000 0000 r/w 0xc08c host 1 interrupt enable vbus interrupt enable id interrupt enable reserved sof/eop interrupt enable reserved 0000 0000 reserved port a wake interrupt enable reserved port a con- nect change interrupt enable reserved done interrupt enable 0000 0000 r/w 0xc08c device 1 interrupt enable vbus interrupt enable id interrupt enable reserved sof/eop timeout inter- rupt enable reserved sof/eop interrupt enable reset interrupt enable 0000 0000 ep7 interrupt enable ep6 interrupt enable ep5 interrupt enable ep4 interrupt enable ep3 interrupt enable ep2 interrupt enable ep1 interrupt enable ep0 interrupt enable 0000 0000 r/w 0xc08e 0xc0ae device n address reserved... 0000 0000 ...reserved address 0000 0000 table 42. register summary (continued) r/w address register bit 15 bit 14 bit 13 bit 12 bit 11 bit 10 bit 9 bit 8 default high bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 default low
cy7c67200 document number: 38-08014 rev. *j page 79 of 93 r/w 0xc090 host 1 status vbus interrupt flag id interrupt flag reserved sof/eop interrupt flag reserved xxxx xxxx reserved port a wake interrupt flag reserved port a con- nect change interrupt flag reserved port a se0 status reserved done interrupt flag xxxx xxxx r/w 0xc090 device 1 status vbus interrupt flag id interrupt flag reserved sof/eop interrupt flag reset interrupt flag xxxx xxxx ep7 interrupt flag ep6 interrupt flag ep5 interrupt flag ep4 interrupt flag ep3 interrupt flag ep2 interrupt flag ep1 interrupt flag ep0 interrupt flag xxxx xxxx r/w 0xc092 0xc0b2 host n sof/eop count reserved count... 0010 1110 ...count 1110 0000 r 0xc092 0xc0b2 device n frame number sof/eop timeout flag sof/eop timeout interrupt count reserved frame... 0000 0000 ...frame 0000 0000 r 0xc094 0xc0b4 host n sof/eop counter reserved counter... ...counter w 0xc094 0xc0b4 device n sof/eop count reserved count... ...count r 0xc096 0xc0b6 host n frame reserved frame... 0000 0000 ...frame 0000 0000 r/w 0xc0ac host 2 interrupt enable reserved sof/eop interrupt enable reserved 0000 0000 reserved port a wake interrupt enable reserved port a con- nect change interrupt enable reserved done interrupt enable 0000 0000 r/w 0xc0ac device 2 interrupt enable reserved sof/eop timeout inter- rupt enable wake interrupt enable sof/eop interrupt enable reset interrupt enable 0000 0000 ep7 interrupt enable ep6 interrupt enable ep5 interrupt enable ep4 interrupt enable ep3 interrupt enable ep2 interrupt enable ep1 interrupt enable ep0 interrupt enable 0000 0000 r/w 0xc0b0 host 2 status reserved sof/eop interrupt flag reserved xxxx xxxx reserved port a wake interrupt flag reserved port a con- nect change interrupt flag reserved port a se0 status reserved done interrupt flag xxxx xxxx r/w 0xc0b0 device 2 status reserved sof/eop timeout interrupt enable wake interrupt flag sof/eop interrupt flag reset interrupt flag xxxx xxxx ep7 interrupt flag ep6 interrupt flag ep5 interrupt flag ep4 interrupt flag ep3 interrupt flag ep2 interrupt flag ep1 interrupt flag ep0 interrupt flag xxxx xxxx r/w 0xc0c6 hpi mailbox message... 0000 0000 ...message 0000 0000 r/w 0xc0c8 spi configuration 3wire enable phase select sck polarity select scale select reserved 1000 0000 master active enable master enable ss enable ss delay select 0001 1111 r/w 0xc0ca spi control sck strobe fifo init byte mode fullduplex ss manual read enable transmit ready receive data ready 0000 0001 transmit empty receive full transmit bit length receive bit length 1000 0000 r/w 0xc0cc spi interrupt enable reserved... 0000 0000 ...reserved receive interrupt enable transmit interrupt enable transfer interrupt enable 0000 0000 r 0xc0ce spi status reserved... 0000 0000 fifo error flag reserved receive interrupt flag transmit interrupt flag transfer interrupt flag 0000 0000 w 0xc0d0 spi interrupt clear reserved... 0000 0000 ...reserved transmit interrupt clear transmit interrupt clear 0000 0000 r/w 0xc0d2 spi crc control crc mode crc enable crc clear receive crc one in crc zero in crc reserved... 0000 0000 ...reserved 0000 0000 r/w 0xc0d4 spi crc value crc.. 1111 1111 ...crc 1111 1111 table 42. register summary (continued) r/w address register bit 15 bit 14 bit 13 bit 12 bit 11 bit 10 bit 9 bit 8 default high bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 default low
cy7c67200 document number: 38-08014 rev. *j page 80 of 93 r/w 0xc0d6 spi data port t reserved xxxx xxxx data xxxx xxxx r/w 0xc0d8 spi transmit address address... 0000 0000 ...address 0000 0000 r/w 0xc0da spi transmit count reserved count... 0000 0000 ...count 0000 0000 r/w 0xc0dc spi receive address address... 0000 0000 ...address 0000 0000 r/w 0xc0de spi receive count reserved count... 0000 0000 ...count 0000 0000 r/w 0xc0e0 uart control reserved... 0000 0000 ...reserved scale select baud select uart enable 0000 0111 r 0xc0e2 uart status reserved... 0000 0000 ...reserved receive full transmit full 0000 0000 r/w 0xc0e4 uart data reserved 0000 0000 data 0000 0000 r hpi status port vbus flag id flag reserved sof/eop2 flag reserved sof/eop1 flag reset2 flag mailbox in flag resume2 flag resume1 flag sie2msg sie1msg done2 flag done1 flag reset1 flag mailbox out flag table 42. register summary (continued) r/w address register bit 15 bit 14 bit 13 bit 12 bit 11 bit 10 bit 9 bit 8 default high bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 default low
cy7c67200 document number: 38-08014 rev. *j page 81 of 93 ordering information ordering code definitions table 43. ordering information ordering code package type pb-free temperature range CY7C67200-48BAXI 48-pin fbga x ?40 to 85 c CY7C67200-48BAXIt 48-pin fbga, tape and reel x ?40 to 85 c cy3663 development kit cy 7 c 67 - xxx xx 48-pin count part number family code: usb technology code: cmos marketing code: cypress products company code: cy = cypress xxxx package type: bax: ball grid array pb-free i thermal rating: i = industrial t tape and reel
cy7c67200 document number: 38-08014 rev. *j page 82 of 93 package diagram figure 78. 48-ball (7.00 mm 7.00 mm 1.2 mm) fbga ba48 51-85096 *i
cy7c67200 document number: 38-08014 rev. *j page 83 of 93 acronyms document conventions units of measure table 44. acronyms used in this document acronym description ac alternating current aec automotive electronics council cpu central processing unit crc cyclic redundancy check dc direct current dma direct memory access eeprom electronically erasable programmable read only memory eop end of packet xram external ram memory fifo first in first out gpio general purpose input/output hss high speed serial hpi host port interface ide integrated device electronics i 2 c inter-integrated circuit kvm keyboard-video-mouse otg on-the-go protocol pll phase locked loop por power-on reset pio programmed input/output pwm pulse width modulation ram random access memory rom read only memory spi serial peripheral interface sie serial-interface-engine se0 single ended zero sof start of frame sram static random access memory tqfp thin quad flat pack ttl transistor-transistor logic uart universal asynchronous receiver/transmitter usb universal serial bus wdt watchdog timer table 45. units of measure symbol unit of measure ns nanosecond vvolt mv millivolt w microwatt a microampere ma milliampere s microsecond ms millisecond mhz megahertz f microfarad pf picofarad mw milliwatt wwatt ppm parts per million c degree celsius
cy7c67200 document number: 38-08014 rev. *j page 84 of 93 errata this section describes the errata for the cy7c67200. details include errata trigger conditions, scope of impact, available work around, and silicon revision applicability. contact your local cypress sales representative if you have questions. part numbers affected cy7c67200 qualification status in production cy7c67200 errata summary the following table defines the errata applicability to available cy7c67200 family devices. an ?x? indicates that the errata pe rtains to the selected device. note errata items, in the table below, are hyperlinked. click on any item entry to jump to its description. part number device characteristics cy7c67200 all packages items cy7c67200 silicon revision fix status 1. hpi write to sie registers x a no fix is currently planned for future silicon versions. use workaround. 2. ide register read when gpio24 pin is low x a no fix is currently planned for future silicon versions. use workaround. 3. uart does not recognize framing errors x a no fix is currently planned for future silicon versions. use workaround. 4. uart does not override gpio control regis- ter x a no fix is currently planned for future silicon versions. use workaround. 5. vbus interrupt ( vbus valid) requires de- bouncing x a no fix is currently planned for future silicon versions. use workaround. 6. coupled sie interrupt enable bits x a no fix is currently planned for future silicon versions. use workaround. 7. un-initialized siexmsg registers x a no fix is currently planned for future silicon versions. use workaround. 8. bios usb peripheral mode: descriptor length x a no fix is currently planned for future silicon versions. use workaround. 9. peripheral short packet issue x a will be fixed in future silicon revision. use workaround. 10. data toggle corruption issue x a will be fixed in future silicon revision. use workaround.
cy7c67200 document number: 38-08014 rev. *j page 85 of 93 1. hpi write to sie registers problem definition writing to the sie2 control register via hpi can corrupt the sie1 control register. writing to the sie1 control register via hpi can corrupt the sie2 control register. parameters affected sie control registers trigger condition(s) when an external processor accesses the sie1 or sie2 register at the same time the internal cy16 cpu is also accessing the opposite sie, the sie accessed by the cy16 cpu will be corrupted. for example, the external processor writes a value of 0x80 to the sie2 register 0xc0b0 while the internal cy16 is doing a read/ write to the sie1 register 0xc08c, the sie1 register 0xc08c, will be corrupted with the value 0x80. scope of impact if the internal cpu and external cpu access the sies at the same time, contention will occur resulting in incorrect data in one of the sie registers. workaround 1. use the lcp comm_write_ctrl_reg to handle the writing to sie registers. 2. use download code to handle sie write commands. 3. avoid accessing sie register from the external cpu. for example: route all the sie interrupts to the software mailbox interrupt registers 0x144 and 0x148. this requires user to create download code. fix status use workaround. no fix is currently planned for future silicon re visions. an implementation example is included in the cypress windows ce driver. 2. ide register read when gpio24 pin is low problem definition part does not service usb isrs when gpio24 pin (also labeled as hpi_int and iordy) is low and any ide register is read. parameters affected usb isrs do not get serviced. trigger conditions the ide registers (0xc050 through 0xc06e) should not be read unless ide is being used. debuggers that read all memory locations while single stepping can cause this situation to manifest itself. scope of impact if debugging and using this pin, your application will appear to hang. workaround when running in stand-alone mode, avoid using the gpio24 pin if possible. fix status other workarounds being investigated. no fix is currently planned for future silicon revisions.
cy7c67200 document number: 38-08014 rev. *j page 86 of 93 3. uart does not recognize framing errors problem definition the uart is not designed to recognize framing errors. parameters affected uart serial communications. trigger conditions some platforms can cause ez-otg to see a string of null characters and cause the uart to get out of sync. scope of impact this can cause the uart to lose connection with the host during serial communications. one example of this is if the uart is used as the debug port to the pc. this problem has occurred on, but is not limited to, dell machines running winxp or win2k. workaround for general use, there is no workaround. if this problem is ex perienced while debugging, try running the debugger on a differen t host (pc/os). otherwise the usb port can be used for the debugging interface. fix status no fix is currently planned for future silicon versions. 4. uart does not override gpio control register problem definition when the uart is enabled, the gpio control register still has control over gpio 6 (uart rx pin). when enabled, the uart should override the gpio control register, which defaults to setting the pin as an input. parameters affected uart serial communications. trigger conditions enabling uart scope of impact gpio 6 uart rx pin is controlled by gpio control register and defaults to an input. the uart mode does not override the gpio control register for this pin and can be inadvertently configured as an output. workaround ensure the gpio control register is written appropriate ly to set gpio6 as an input when the uart is enabled. fix status no fix is currently planned for future silicon versions.
cy7c67200 document number: 38-08014 rev. *j page 87 of 93 5. vbus interrupt (vbus valid) requires debouncing problem definition the vbus interrupt in the host/device status registers [0xc090 and 0xc0b0] and otg control register [0xc098] triggers multiple times whenever vbus is turned on. it should only trigger once when vbus rises above 4.4 v and once when vbus falls from above 4.4 v to 0 v. parameters affected electrical. trigger conditions vbus turned on. scope of impact host/device registers and otg control register trigger multiple times. workaround when reading the status of this interrupt, a software debounce should be implemented. fix status no fix is currently planned for future silicon versions. 6. coupled sie interrupt enable bits problem definition host/device 1 sie events will still trigger an interrupt when only the host/device 2 sie interrupt enable is set and vise versa . parameters affected host/device sie interrupts. trigger conditions setting only 1 host/devic e sie interrupt enable. scope of impact the host/device global interrupt enable bits can not be used to disable each host/device sie independently. these bits are foun d in the interrupt enable register (0xc00e). workaround if an sie interrupt is desired, both host/device 1 and host/devic e 2 interrupt enable bits should be set in the global interrup t enable register (0xc00e). to properly mask an sie interrupt to a single sie, the lower level host/device interrupt enable registers (0xc08c and 0xc0ac) must be used. for example, setting the host/device 2 ie register to 0x0000 will prevent any host/device 2 events from generating a host/device interrupt. to disable all sie interrupts, both host/device interrupt enable bits in the interrupt enable register should be cleared. fix status no fix is currently planned for future silicon versions . examples provided in the development kit software.
cy7c67200 document number: 38-08014 rev. *j page 88 of 93 7. un-initialized siexmsg registers problem definition the sie1msg and sie2msg registers [0x0144 and 0x0148] are not initialized at power up. parameters affected hpi interrupts. trigger conditions power-up initialization. scope of impact if using the hpi interface in coprocessor mode, random data w ill be written to the sie1msg and sie2msg registers [0x0144 and 0x0148] at power up. this will cause two improper hpi interrupts (h pi_intr) to occur, one for each of the two siexmsg registers . workaround the external processor should clear the siexmsg registers [0x0144 and 0x0148] shortl y after nreset is de-asserted and prior to the expected processing of proper hpi interr upts (generally 10ms after nreset is de-asserted.) fix status no fix is currently planned for future silicon versions. 8. bios usb peripheral mode: descriptor length problem definition the bios will not properly return a descriptor or set of descriptors if the length is a multiple of the control endpoint?s maxi mum packet size. parameters affected control endpoint maximum packet size. trigger conditions get descriptor requests. scope of impact if the descriptor length is a multiple of the maximum packet size, the bios will respond with a stall instead of a zero-length data packet for the final in request. workaround if the requested descriptor length is a multiple of the maximum packet size, then either the maximum packet size or the descrip tor length needs to change. a descriptor length can be increased by simply adding a padded byte to the end of a descriptor and increasing the descriptor length byte by one. section 9.5 (descr iptor) of the usb2.0 specification allows a descriptor length t o be larger than the value defined in the specification. fix status no fix is currently planned for future silicon versions.
cy7c67200 document number: 38-08014 rev. *j page 89 of 93 9. peripheral short packet issue problem definition when a sie is configured as a peripheral, the susbx_receive function does not invoke the callback function when it receives a short packet. parameters affected siex endpoint x interrupt (interrupt 32-47). trigger conditions this issue is seen when a sie is configured as a peripheral during an out data transfer when the host sends a zero length or short packet. if this occurs the bios will behave as if a full packet was received and will continue to accept data until the d evice n endpoint n count register value is satisfied. scope of impact all peripheral functions are susceptible to this as it is a normal occurrence with usb traffic. workaround to fix this problem the siex endpoint x interrupt must be replaced for any peripheral endpoint that is configured as an out end point. 1. acquire the file called susb1.s from cypress support or by downloading a newer version of the frameworks that has had this fix applied and includes susb1.s. 2. modify fwxcfg.h in your project to have the following flags and define/undef the fix for the endpoints you are using: #define fix_usb1_ep1 #define fix_usb1_ep2 #undef fix_usb1_ep3 #undef fix_usb1_ep4 #undef fix_usb1_ep5 #undef fix_usb1_ep6 #undef fix_usb1_ep7 #undef fix_usb2_ep1 #undef fix_usb2_ep2 #undef fix_usb2_ep3 #undef fix_usb2_ep4 #undef fix_usb2_ep5 #undef fix_usb2_ep6 #undef fix_usb2_ep7 3. add the new susb1.s to the included assembly source files in the make file. for example: asm_src := startup.s isrs.s susb1.s 4. add usb_init somewhere in the startup code. this will likely be in fwxmain.c as demonstrated below: void fwx_program_init(void) { void usb_init(); /* define the prototype */ usb_init(); fwx_init(); /* initialize everything in the base framework. */ } 5. build the project using the modified make file. fix status the rom version of the bios will be updated during any future silicon rolls. no current roll of the part currently exists. 10.data toggle corruption issue
cy7c67200 document number: 38-08014 rev. *j page 90 of 93 problem definition when a sie is configured as a peripheral, data toggle corruption as specified in the usb 2.0 spec, section 8.6.4, does not work as specified. parameters affected siex endpoint x interrupt (interrupt 32-47). trigger conditions this issue is seen when a sie is configured as a peripheral a nd the host sends an incorrect data toggle. according to the usb specification, when an incorrect data toggle is seen from the host the peripheral should throw away the data but increment the data toggle bit to re-synchronize the data toggle bits. in the curren t rom bios the siex endpoint x interrupt will ignore the data t oggle error and accept the data. scope of impact all peripheral functions are susceptible to this as it is a normal occurrence with usb traffic. workaround to fix this problem the siex endpoint x interrupt must be replaced for any endpoint that is configured as an out endpoint. 1. acquire the file called susb1.s from cypress support or by downloading a newer version of the frameworks that has this included. 2. modify fwxcfg.h in your project to have the following flags and define/undef the fix for the endpoints you are using: #define fix_usb1_ep1 #define fix_usb1_ep2 #undef fix_usb1_ep3 #undef fix_usb1_ep4 #undef fix_usb1_ep5 #undef fix_usb1_ep6 #undef fix_usb1_ep7 #undef fix_usb2_ep1 #undef fix_usb2_ep2 #undef fix_usb2_ep3 #undef fix_usb2_ep4 #undef fix_usb2_ep5 #undef fix_usb2_ep6 #undef fix_usb2_ep7 3. add the new susb1.s to the included assembly source files in the make file. for example: asm_src := startup.s isrs.s susb1.s 4. add usb_init somewhere in the startup code. this will likely be in fwxmain.c as demonstrated below: void fwx_program_init(void) { void usb_init(); /* define the prototype */ usb_init(); fwx_init(); /* initialize everything in the base framework. */ } 5. build the project using the modified make file. fix status the rom version of the bios will be updated during any future silicon rolls. no current roll of the part currently exists.
cy7c67200 document number: 38-08014 rev. *j page 91 of 93 document history page document title: cy7c67200 ez-otg? programmable usb on-the-go host/peripheral controller document number: 38-08014 revision ecn orig. of change submission date description of change ** 111872 mul 03/22/02 new data sheet *a 116988 mul 08/23/02 preliminary data sheet *b 124954 mul 04/10/03 added memory map section and ordering information section moved functional register map tables into register section general clean-up changed from ?preliminary? to ?preliminary confidential? *c 126211 mul 05/23/03 added interface description section and power savings and reset section added char data general clean-up removed dram, mdma, and epp added ?programmable? to the title page *d 127334 kkv 05/29/03 corrected font to enable correct symbol display *e 129394 mul 10/07/03 final data sheet changed memory map section added usb otg logo general clean-up *f 472875 ari see ecn removed ?power consumpt ion? bullet from the features bullet list. corrected number gpio[31:20] to read gpio[31:30] in section ?standalone mode? . made sentence into a note in section ?reset pin? and repeated the note in section ?host port interface (hpi)? . corrected the host/device 1 interrupt enable (bit 8) information in section ?interrupt enable register [0xc00e] [r/w] [7]? . corrected data on write protect enable (bit 15) section ?gpio control register [0xc006] [r/w]? to read ?the gpio mode select [15:8] bits are read only until a chip reset?. re-wrote the register description in section ?siexmsg register [w] [10]? . put document on 2-column template and corrected grammar. put the figure captions at the top of the figures per new template specifications. added static discharge voltage information in section ?absolute maximum ratings? added compliance statement and tid in section ?usb transceiver? . *g 567317 kkvtmp see ecn added the lead free informatio n on the ordering information section. imple- mented the new template with no numbers on the headings. *h 3378752 nmma 09/21/11 updated template and styles according to current cypress standards. updated pin description in ordering information table. added acronyms and units of measure. added ordering code definitions. *i 3997630 prji 05/11/2013 added errata .
cy7c67200 document number: 38-08014 rev. *j page 92 of 93 *j 4082823 prji 07/31/2013 added errata footnotes (note 1, 2, 7, 8, 9, 10, 11). updated interface descriptions : updated uart interface [1] : added note 1 and referred the same note in the heading. updated i2c eeprom interface [2] : added note 2 and referred the same note in the heading. updated registers : updated processor control registers : updated interrupt enable register [0xc00e] [r/w] [7] : added note 7 and referred the same note in the heading. updated general usb registers [8] : added note 8 and referred the same note in the heading. updated otg control registers [9] : added note 9 and referred the same note in the heading. updated hpi registers : updated siexmsg register [w] [10] : added note 10 and referred the same note in the heading. updated pin descriptions : added note 11 and referred the same note in ?gpio24/int/irq0? pin. updated in new template. completing sunset review. document history page (continued) document title: cy7c67200 ez-otg? programmable usb on-the-go host/peripheral controller document number: 38-08014 revision ecn orig. of change submission date description of change
document number: 38-08014 rev. *j revised july 31, 2013 page 93 of 93 all products and company names mentioned in this document may be the trademarks of their respective holders. cy7c67200 ? cypress semiconductor corporation, 2006-2013. the information contained herein is subject to change without notice. cypress s emiconductor corporation assumes no responsibility for the use of any circuitry other than circuitry embodied in a cypress product. nor does it convey or imply any license under patent or other rights. cypress products are not warranted nor intended to be used for medical, life support, life saving, critical control or safety applications, unless pursuant to an express written agreement wi th cypress. furthermore, cypress does not authorize its products for use as critical components in life-support systems where a malfunction or failure may reasonably be expected to result in significant injury to the user. the inclusion of cypress products in life-support systems application implies that the manufacturer assumes all risk of such use and in doing so indemnifies cypress against all charges. any source code (software and/or firmware) is owned by cypress semiconductor corporation (cypress) and is protected by and subj ect to worldwide patent protection (united states and foreign), united states copyright laws and internatio nal treaty provisions. cypress hereby grants to licensee a personal, non-exclusive, non-transferable license to copy, use, modify, create derivative works of, and compile the cypress source code and derivative works for the sole purpose of creating custom software and or firmware in su pport of licensee product to be used only in conjunction with a cypress integrated circuit as specified in the applicable agreement. any reproduction, modification, translation, compilation, or repre sentation of this source code except as specified above is prohibited without the express written permission of cypress. disclaimer: cypress makes no warranty of any kind, express or implied, with regard to this material, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose. cypress reserves the right to make changes without further notice to t he materials described herein. cypress does not assume any liability arising out of the application or use of any product or circuit described herein. cypress does not authori ze its products for use as critical components in life-support systems where a malfunction or failure may reasonably be expected to result in significant injury to the user. the inclusion of cypress? prod uct in a life-support systems application implies that the manufacturer assumes all risk of such use and in doing so indemnifies cypress against all charges. use may be limited by and subject to the applicable cypress software license agreement. sales, solutions, and legal information worldwide sales and design support cypress maintains a worldwide network of offices, solution center s, manufacturer?s representatives, and distributors. to find t he office closest to you, visit us at cypress locations . products automotive cypress.co m/go/automotive clocks & buffers cypress.com/go/clocks interface cypress. com/go/interface lighting & power control cypress.com/go/powerpsoc cypress.com/go/plc memory cypress.com/go/memory psoc cypress.com/go/psoc touch sensing cyp ress.com/go/touch usb controllers cypress.com/go/usb wireless/rf cypre ss.com/go/wireless psoc ? solutions psoc.cypress.com/solutions psoc 1 | psoc 3 | psoc 4 | psoc 5lp cypress developer community community | forums | blogs | video | training technical support cypress.com/go/support


▲Up To Search▲   

 
Price & Availability of CY7C67200-48BAXI

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X